From cdf9e7e8bc4892f460ae408d2c76ddb311082ef4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Jun 2025 21:57:09 +0000 Subject: [PATCH 01/17] Bump Submodule/github/rest-api-description from `bf4af7c` to `23d16a0` Bumps [Submodule/github/rest-api-description](https://github.com/github/rest-api-description) from `bf4af7c` to `23d16a0`. - [Release notes](https://github.com/github/rest-api-description/releases) - [Commits](https://github.com/github/rest-api-description/compare/bf4af7c248a68067f570e103053a01b1c9725a92...23d16a0c0808c8241b1076d63e8d3f2e75cb6632) --- updated-dependencies: - dependency-name: Submodule/github/rest-api-description dependency-version: 23d16a0c0808c8241b1076d63e8d3f2e75cb6632 dependency-type: direct:production ... Signed-off-by: dependabot[bot] --- Submodule/github/rest-api-description | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Submodule/github/rest-api-description b/Submodule/github/rest-api-description index bf4af7c248..23d16a0c08 160000 --- a/Submodule/github/rest-api-description +++ b/Submodule/github/rest-api-description @@ -1 +1 @@ -Subproject commit bf4af7c248a68067f570e103053a01b1c9725a92 +Subproject commit 23d16a0c0808c8241b1076d63e8d3f2e75cb6632 From 415e83f99424d3c32402280212a83457cab717c0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:20:00 +0000 Subject: [PATCH 02/17] Commit via running: make Sources/actions --- Sources/actions/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/actions/Types.swift b/Sources/actions/Types.swift index 14512ca9f7..35c46944c0 100644 --- a/Sources/actions/Types.swift +++ b/Sources/actions/Types.swift @@ -6414,6 +6414,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -6504,6 +6528,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -6591,7 +6616,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -6680,6 +6706,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -6769,6 +6796,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// - Remark: Generated from `#/components/schemas/actions-cache-usage-org-enterprise`. From e1c4a926e3fd1116b7c848c60fb1658c386fc2c3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:20:24 +0000 Subject: [PATCH 03/17] Commit via running: make Sources/activity --- Sources/activity/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/activity/Types.swift b/Sources/activity/Types.swift index 6957d3fc54..11b3d4f3b2 100644 --- a/Sources/activity/Types.swift +++ b/Sources/activity/Types.swift @@ -4175,6 +4175,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -4265,6 +4289,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -4352,7 +4377,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -4441,6 +4467,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -4530,6 +4557,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// Thread From 515625d80f58268a9c3a49bfb4deecbd91245d8f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:21:38 +0000 Subject: [PATCH 04/17] Commit via running: make Sources/checks --- Sources/checks/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/checks/Types.swift b/Sources/checks/Types.swift index 2be69e720b..f017adac44 100644 --- a/Sources/checks/Types.swift +++ b/Sources/checks/Types.swift @@ -1435,6 +1435,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -1525,6 +1549,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -1612,7 +1637,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -1701,6 +1727,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -1790,6 +1817,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// An object without any properties. From e47bc7d3adf62cacde15184bbe219b36d9ee2a67 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:23:15 +0000 Subject: [PATCH 05/17] Commit via running: make Sources/dependabot --- Sources/dependabot/Client.swift | 22 ++ Sources/dependabot/Types.swift | 532 +++++++++++++++++++++++++++++--- 2 files changed, 509 insertions(+), 45 deletions(-) diff --git a/Sources/dependabot/Client.swift b/Sources/dependabot/Client.swift index 2f52d91878..0222c62e55 100644 --- a/Sources/dependabot/Client.swift +++ b/Sources/dependabot/Client.swift @@ -298,6 +298,20 @@ public struct Client: APIProtocol { method: .get ) suppressMutabilityWarning(&request) + try converter.setQueryItemAsURI( + in: &request, + style: .form, + explode: true, + name: "page", + value: input.query.page + ) + try converter.setQueryItemAsURI( + in: &request, + style: .form, + explode: true, + name: "per_page", + value: input.query.perPage + ) converter.setAcceptHeader( in: &request.headerFields, contentTypes: input.headers.accept @@ -390,6 +404,14 @@ public struct Client: APIProtocol { /// > This operation supports both server-to-server and user-to-server access. /// Unauthorized users will not see the existence of this endpoint. /// + /// **Example request body:** + /// ```json + /// { + /// "repository_ids_to_add": [123, 456], + /// "repository_ids_to_remove": [789] + /// } + /// ``` + /// /// - Remark: HTTP `PATCH /organizations/{org}/dependabot/repository-access`. /// - Remark: Generated from `#/paths//organizations/{org}/dependabot/repository-access/patch(dependabot/update-repository-access-for-org)`. public func dependabotUpdateRepositoryAccessForOrg(_ input: Operations.DependabotUpdateRepositoryAccessForOrg.Input) async throws -> Operations.DependabotUpdateRepositoryAccessForOrg.Output { diff --git a/Sources/dependabot/Types.swift b/Sources/dependabot/Types.swift index 9cecb35435..524f976bf6 100644 --- a/Sources/dependabot/Types.swift +++ b/Sources/dependabot/Types.swift @@ -39,6 +39,14 @@ public protocol APIProtocol: Sendable { /// > This operation supports both server-to-server and user-to-server access. /// Unauthorized users will not see the existence of this endpoint. /// + /// **Example request body:** + /// ```json + /// { + /// "repository_ids_to_add": [123, 456], + /// "repository_ids_to_remove": [789] + /// } + /// ``` + /// /// - Remark: HTTP `PATCH /organizations/{org}/dependabot/repository-access`. /// - Remark: Generated from `#/paths//organizations/{org}/dependabot/repository-access/patch(dependabot/update-repository-access-for-org)`. func dependabotUpdateRepositoryAccessForOrg(_ input: Operations.DependabotUpdateRepositoryAccessForOrg.Input) async throws -> Operations.DependabotUpdateRepositoryAccessForOrg.Output @@ -266,10 +274,12 @@ extension APIProtocol { /// - Remark: Generated from `#/paths//organizations/{org}/dependabot/repository-access/get(dependabot/repository-access-for-org)`. public func dependabotRepositoryAccessForOrg( path: Operations.DependabotRepositoryAccessForOrg.Input.Path, + query: Operations.DependabotRepositoryAccessForOrg.Input.Query = .init(), headers: Operations.DependabotRepositoryAccessForOrg.Input.Headers = .init() ) async throws -> Operations.DependabotRepositoryAccessForOrg.Output { try await dependabotRepositoryAccessForOrg(Operations.DependabotRepositoryAccessForOrg.Input( path: path, + query: query, headers: headers )) } @@ -279,6 +289,14 @@ extension APIProtocol { /// > This operation supports both server-to-server and user-to-server access. /// Unauthorized users will not see the existence of this endpoint. /// + /// **Example request body:** + /// ```json + /// { + /// "repository_ids_to_add": [123, 456], + /// "repository_ids_to_remove": [789] + /// } + /// ``` + /// /// - Remark: HTTP `PATCH /organizations/{org}/dependabot/repository-access`. /// - Remark: Generated from `#/paths//organizations/{org}/dependabot/repository-access/patch(dependabot/update-repository-access-for-org)`. public func dependabotUpdateRepositoryAccessForOrg( @@ -2911,6 +2929,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -3001,6 +3043,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -3088,7 +3131,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -3177,6 +3221,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -3266,6 +3311,386 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" + } + } + /// A GitHub repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository`. + public struct NullableSimpleRepository: Codable, Hashable, Sendable { + /// A unique identifier of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/id`. + public var id: Swift.Int64 + /// The GraphQL identifier of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/node_id`. + public var nodeId: Swift.String + /// The name of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/name`. + public var name: Swift.String + /// The full, globally unique, name of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/full_name`. + public var fullName: Swift.String + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/owner`. + public var owner: Components.Schemas.SimpleUser + /// Whether the repository is private. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/private`. + public var _private: Swift.Bool + /// The URL to view the repository on GitHub.com. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/html_url`. + public var htmlUrl: Swift.String + /// The repository description. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/description`. + public var description: Swift.String? + /// Whether the repository is a fork. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/fork`. + public var fork: Swift.Bool + /// The URL to get more information about the repository from the GitHub API. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/url`. + public var url: Swift.String + /// A template for the API URL to download the repository as an archive. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/archive_url`. + public var archiveUrl: Swift.String + /// A template for the API URL to list the available assignees for issues in the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/assignees_url`. + public var assigneesUrl: Swift.String + /// A template for the API URL to create or retrieve a raw Git blob in the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/blobs_url`. + public var blobsUrl: Swift.String + /// A template for the API URL to get information about branches in the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/branches_url`. + public var branchesUrl: Swift.String + /// A template for the API URL to get information about collaborators of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/collaborators_url`. + public var collaboratorsUrl: Swift.String + /// A template for the API URL to get information about comments on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/comments_url`. + public var commentsUrl: Swift.String + /// A template for the API URL to get information about commits on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/commits_url`. + public var commitsUrl: Swift.String + /// A template for the API URL to compare two commits or refs. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/compare_url`. + public var compareUrl: Swift.String + /// A template for the API URL to get the contents of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/contents_url`. + public var contentsUrl: Swift.String + /// A template for the API URL to list the contributors to the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/contributors_url`. + public var contributorsUrl: Swift.String + /// The API URL to list the deployments of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/deployments_url`. + public var deploymentsUrl: Swift.String + /// The API URL to list the downloads on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/downloads_url`. + public var downloadsUrl: Swift.String + /// The API URL to list the events of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/events_url`. + public var eventsUrl: Swift.String + /// The API URL to list the forks of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/forks_url`. + public var forksUrl: Swift.String + /// A template for the API URL to get information about Git commits of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/git_commits_url`. + public var gitCommitsUrl: Swift.String + /// A template for the API URL to get information about Git refs of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/git_refs_url`. + public var gitRefsUrl: Swift.String + /// A template for the API URL to get information about Git tags of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/git_tags_url`. + public var gitTagsUrl: Swift.String + /// A template for the API URL to get information about issue comments on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/issue_comment_url`. + public var issueCommentUrl: Swift.String + /// A template for the API URL to get information about issue events on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/issue_events_url`. + public var issueEventsUrl: Swift.String + /// A template for the API URL to get information about issues on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/issues_url`. + public var issuesUrl: Swift.String + /// A template for the API URL to get information about deploy keys on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/keys_url`. + public var keysUrl: Swift.String + /// A template for the API URL to get information about labels of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/labels_url`. + public var labelsUrl: Swift.String + /// The API URL to get information about the languages of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/languages_url`. + public var languagesUrl: Swift.String + /// The API URL to merge branches in the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/merges_url`. + public var mergesUrl: Swift.String + /// A template for the API URL to get information about milestones of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/milestones_url`. + public var milestonesUrl: Swift.String + /// A template for the API URL to get information about notifications on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/notifications_url`. + public var notificationsUrl: Swift.String + /// A template for the API URL to get information about pull requests on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/pulls_url`. + public var pullsUrl: Swift.String + /// A template for the API URL to get information about releases on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/releases_url`. + public var releasesUrl: Swift.String + /// The API URL to list the stargazers on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/stargazers_url`. + public var stargazersUrl: Swift.String + /// A template for the API URL to get information about statuses of a commit. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/statuses_url`. + public var statusesUrl: Swift.String + /// The API URL to list the subscribers on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/subscribers_url`. + public var subscribersUrl: Swift.String + /// The API URL to subscribe to notifications for this repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/subscription_url`. + public var subscriptionUrl: Swift.String + /// The API URL to get information about tags on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/tags_url`. + public var tagsUrl: Swift.String + /// The API URL to list the teams on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/teams_url`. + public var teamsUrl: Swift.String + /// A template for the API URL to create or retrieve a raw Git tree of the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/trees_url`. + public var treesUrl: Swift.String + /// The API URL to list the hooks on the repository. + /// + /// - Remark: Generated from `#/components/schemas/nullable-simple-repository/hooks_url`. + public var hooksUrl: Swift.String + /// Creates a new `NullableSimpleRepository`. + /// + /// - Parameters: + /// - id: A unique identifier of the repository. + /// - nodeId: The GraphQL identifier of the repository. + /// - name: The name of the repository. + /// - fullName: The full, globally unique, name of the repository. + /// - owner: + /// - _private: Whether the repository is private. + /// - htmlUrl: The URL to view the repository on GitHub.com. + /// - description: The repository description. + /// - fork: Whether the repository is a fork. + /// - url: The URL to get more information about the repository from the GitHub API. + /// - archiveUrl: A template for the API URL to download the repository as an archive. + /// - assigneesUrl: A template for the API URL to list the available assignees for issues in the repository. + /// - blobsUrl: A template for the API URL to create or retrieve a raw Git blob in the repository. + /// - branchesUrl: A template for the API URL to get information about branches in the repository. + /// - collaboratorsUrl: A template for the API URL to get information about collaborators of the repository. + /// - commentsUrl: A template for the API URL to get information about comments on the repository. + /// - commitsUrl: A template for the API URL to get information about commits on the repository. + /// - compareUrl: A template for the API URL to compare two commits or refs. + /// - contentsUrl: A template for the API URL to get the contents of the repository. + /// - contributorsUrl: A template for the API URL to list the contributors to the repository. + /// - deploymentsUrl: The API URL to list the deployments of the repository. + /// - downloadsUrl: The API URL to list the downloads on the repository. + /// - eventsUrl: The API URL to list the events of the repository. + /// - forksUrl: The API URL to list the forks of the repository. + /// - gitCommitsUrl: A template for the API URL to get information about Git commits of the repository. + /// - gitRefsUrl: A template for the API URL to get information about Git refs of the repository. + /// - gitTagsUrl: A template for the API URL to get information about Git tags of the repository. + /// - issueCommentUrl: A template for the API URL to get information about issue comments on the repository. + /// - issueEventsUrl: A template for the API URL to get information about issue events on the repository. + /// - issuesUrl: A template for the API URL to get information about issues on the repository. + /// - keysUrl: A template for the API URL to get information about deploy keys on the repository. + /// - labelsUrl: A template for the API URL to get information about labels of the repository. + /// - languagesUrl: The API URL to get information about the languages of the repository. + /// - mergesUrl: The API URL to merge branches in the repository. + /// - milestonesUrl: A template for the API URL to get information about milestones of the repository. + /// - notificationsUrl: A template for the API URL to get information about notifications on the repository. + /// - pullsUrl: A template for the API URL to get information about pull requests on the repository. + /// - releasesUrl: A template for the API URL to get information about releases on the repository. + /// - stargazersUrl: The API URL to list the stargazers on the repository. + /// - statusesUrl: A template for the API URL to get information about statuses of a commit. + /// - subscribersUrl: The API URL to list the subscribers on the repository. + /// - subscriptionUrl: The API URL to subscribe to notifications for this repository. + /// - tagsUrl: The API URL to get information about tags on the repository. + /// - teamsUrl: The API URL to list the teams on the repository. + /// - treesUrl: A template for the API URL to create or retrieve a raw Git tree of the repository. + /// - hooksUrl: The API URL to list the hooks on the repository. + public init( + id: Swift.Int64, + nodeId: Swift.String, + name: Swift.String, + fullName: Swift.String, + owner: Components.Schemas.SimpleUser, + _private: Swift.Bool, + htmlUrl: Swift.String, + description: Swift.String? = nil, + fork: Swift.Bool, + url: Swift.String, + archiveUrl: Swift.String, + assigneesUrl: Swift.String, + blobsUrl: Swift.String, + branchesUrl: Swift.String, + collaboratorsUrl: Swift.String, + commentsUrl: Swift.String, + commitsUrl: Swift.String, + compareUrl: Swift.String, + contentsUrl: Swift.String, + contributorsUrl: Swift.String, + deploymentsUrl: Swift.String, + downloadsUrl: Swift.String, + eventsUrl: Swift.String, + forksUrl: Swift.String, + gitCommitsUrl: Swift.String, + gitRefsUrl: Swift.String, + gitTagsUrl: Swift.String, + issueCommentUrl: Swift.String, + issueEventsUrl: Swift.String, + issuesUrl: Swift.String, + keysUrl: Swift.String, + labelsUrl: Swift.String, + languagesUrl: Swift.String, + mergesUrl: Swift.String, + milestonesUrl: Swift.String, + notificationsUrl: Swift.String, + pullsUrl: Swift.String, + releasesUrl: Swift.String, + stargazersUrl: Swift.String, + statusesUrl: Swift.String, + subscribersUrl: Swift.String, + subscriptionUrl: Swift.String, + tagsUrl: Swift.String, + teamsUrl: Swift.String, + treesUrl: Swift.String, + hooksUrl: Swift.String + ) { + self.id = id + self.nodeId = nodeId + self.name = name + self.fullName = fullName + self.owner = owner + self._private = _private + self.htmlUrl = htmlUrl + self.description = description + self.fork = fork + self.url = url + self.archiveUrl = archiveUrl + self.assigneesUrl = assigneesUrl + self.blobsUrl = blobsUrl + self.branchesUrl = branchesUrl + self.collaboratorsUrl = collaboratorsUrl + self.commentsUrl = commentsUrl + self.commitsUrl = commitsUrl + self.compareUrl = compareUrl + self.contentsUrl = contentsUrl + self.contributorsUrl = contributorsUrl + self.deploymentsUrl = deploymentsUrl + self.downloadsUrl = downloadsUrl + self.eventsUrl = eventsUrl + self.forksUrl = forksUrl + self.gitCommitsUrl = gitCommitsUrl + self.gitRefsUrl = gitRefsUrl + self.gitTagsUrl = gitTagsUrl + self.issueCommentUrl = issueCommentUrl + self.issueEventsUrl = issueEventsUrl + self.issuesUrl = issuesUrl + self.keysUrl = keysUrl + self.labelsUrl = labelsUrl + self.languagesUrl = languagesUrl + self.mergesUrl = mergesUrl + self.milestonesUrl = milestonesUrl + self.notificationsUrl = notificationsUrl + self.pullsUrl = pullsUrl + self.releasesUrl = releasesUrl + self.stargazersUrl = stargazersUrl + self.statusesUrl = statusesUrl + self.subscribersUrl = subscribersUrl + self.subscriptionUrl = subscriptionUrl + self.tagsUrl = tagsUrl + self.teamsUrl = teamsUrl + self.treesUrl = treesUrl + self.hooksUrl = hooksUrl + } + public enum CodingKeys: String, CodingKey { + case id + case nodeId = "node_id" + case name + case fullName = "full_name" + case owner + case _private = "private" + case htmlUrl = "html_url" + case description + case fork + case url + case archiveUrl = "archive_url" + case assigneesUrl = "assignees_url" + case blobsUrl = "blobs_url" + case branchesUrl = "branches_url" + case collaboratorsUrl = "collaborators_url" + case commentsUrl = "comments_url" + case commitsUrl = "commits_url" + case compareUrl = "compare_url" + case contentsUrl = "contents_url" + case contributorsUrl = "contributors_url" + case deploymentsUrl = "deployments_url" + case downloadsUrl = "downloads_url" + case eventsUrl = "events_url" + case forksUrl = "forks_url" + case gitCommitsUrl = "git_commits_url" + case gitRefsUrl = "git_refs_url" + case gitTagsUrl = "git_tags_url" + case issueCommentUrl = "issue_comment_url" + case issueEventsUrl = "issue_events_url" + case issuesUrl = "issues_url" + case keysUrl = "keys_url" + case labelsUrl = "labels_url" + case languagesUrl = "languages_url" + case mergesUrl = "merges_url" + case milestonesUrl = "milestones_url" + case notificationsUrl = "notifications_url" + case pullsUrl = "pulls_url" + case releasesUrl = "releases_url" + case stargazersUrl = "stargazers_url" + case statusesUrl = "statuses_url" + case subscribersUrl = "subscribers_url" + case subscriptionUrl = "subscription_url" + case tagsUrl = "tags_url" + case teamsUrl = "teams_url" + case treesUrl = "trees_url" + case hooksUrl = "hooks_url" } } /// Information about repositories that Dependabot is able to access in an organization @@ -3284,7 +3709,7 @@ public enum Components { /// - Remark: Generated from `#/components/schemas/dependabot-repository-access-details/default_level`. public var defaultLevel: Components.Schemas.DependabotRepositoryAccessDetails.DefaultLevelPayload? /// - Remark: Generated from `#/components/schemas/dependabot-repository-access-details/accessible_repositories`. - public var accessibleRepositories: [Components.Schemas.SimpleRepository]? + public var accessibleRepositories: [Components.Schemas.NullableSimpleRepository]? /// Creates a new `DependabotRepositoryAccessDetails`. /// /// - Parameters: @@ -3292,7 +3717,7 @@ public enum Components { /// - accessibleRepositories: public init( defaultLevel: Components.Schemas.DependabotRepositoryAccessDetails.DefaultLevelPayload? = nil, - accessibleRepositories: [Components.Schemas.SimpleRepository]? = nil + accessibleRepositories: [Components.Schemas.NullableSimpleRepository]? = nil ) { self.defaultLevel = defaultLevel self.accessibleRepositories = accessibleRepositories @@ -3308,7 +3733,7 @@ public enum Components { forKey: .defaultLevel ) self.accessibleRepositories = try container.decodeIfPresent( - [Components.Schemas.SimpleRepository].self, + [Components.Schemas.NullableSimpleRepository].self, forKey: .accessibleRepositories ) try decoder.ensureNoAdditionalProperties(knownKeys: [ @@ -4516,6 +4941,30 @@ public enum Operations { } } public var path: Operations.DependabotRepositoryAccessForOrg.Input.Path + /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/GET/query`. + public struct Query: Sendable, Hashable { + /// The page number of results to fetch. + /// + /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/GET/query/page`. + public var page: Swift.Int? + /// Number of results per page. + /// + /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/GET/query/per_page`. + public var perPage: Swift.Int? + /// Creates a new `Query`. + /// + /// - Parameters: + /// - page: The page number of results to fetch. + /// - perPage: Number of results per page. + public init( + page: Swift.Int? = nil, + perPage: Swift.Int? = nil + ) { + self.page = page + self.perPage = perPage + } + } + public var query: Operations.DependabotRepositoryAccessForOrg.Input.Query /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/GET/header`. public struct Headers: Sendable, Hashable { public var accept: [OpenAPIRuntime.AcceptHeaderContentType] @@ -4532,12 +4981,15 @@ public enum Operations { /// /// - Parameters: /// - path: + /// - query: /// - headers: public init( path: Operations.DependabotRepositoryAccessForOrg.Input.Path, + query: Operations.DependabotRepositoryAccessForOrg.Input.Query = .init(), headers: Operations.DependabotRepositoryAccessForOrg.Input.Headers = .init() ) { self.path = path + self.query = query self.headers = headers } } @@ -4676,6 +5128,14 @@ public enum Operations { /// > This operation supports both server-to-server and user-to-server access. /// Unauthorized users will not see the existence of this endpoint. /// + /// **Example request body:** + /// ```json + /// { + /// "repository_ids_to_add": [123, 456], + /// "repository_ids_to_remove": [789] + /// } + /// ``` + /// /// - Remark: HTTP `PATCH /organizations/{org}/dependabot/repository-access`. /// - Remark: Generated from `#/paths//organizations/{org}/dependabot/repository-access/patch(dependabot/update-repository-access-for-org)`. public enum DependabotUpdateRepositoryAccessForOrg { @@ -4711,48 +5171,30 @@ public enum Operations { /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody`. @frozen public enum Body: Sendable, Hashable { /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/json`. - @frozen public enum JsonPayload: Codable, Hashable, Sendable { - /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/json/case1`. - public struct Case1Payload: Codable, Hashable, Sendable { - /// Creates a new `Case1Payload`. - public init() {} - } - /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/json/case1`. - case case1(Operations.DependabotUpdateRepositoryAccessForOrg.Input.Body.JsonPayload.Case1Payload) - /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/json/case2`. - public struct Case2Payload: Codable, Hashable, Sendable { - /// Creates a new `Case2Payload`. - public init() {} - } - /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/json/case2`. - case case2(Operations.DependabotUpdateRepositoryAccessForOrg.Input.Body.JsonPayload.Case2Payload) - public init(from decoder: any Decoder) throws { - var errors: [any Error] = [] - do { - self = .case1(try .init(from: decoder)) - return - } catch { - errors.append(error) - } - do { - self = .case2(try .init(from: decoder)) - return - } catch { - errors.append(error) - } - throw Swift.DecodingError.failedToDecodeOneOfSchema( - type: Self.self, - codingPath: decoder.codingPath, - errors: errors - ) + public struct JsonPayload: Codable, Hashable, Sendable { + /// List of repository IDs to add. + /// + /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/json/repository_ids_to_add`. + public var repositoryIdsToAdd: [Swift.Int]? + /// List of repository IDs to remove. + /// + /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/json/repository_ids_to_remove`. + public var repositoryIdsToRemove: [Swift.Int]? + /// Creates a new `JsonPayload`. + /// + /// - Parameters: + /// - repositoryIdsToAdd: List of repository IDs to add. + /// - repositoryIdsToRemove: List of repository IDs to remove. + public init( + repositoryIdsToAdd: [Swift.Int]? = nil, + repositoryIdsToRemove: [Swift.Int]? = nil + ) { + self.repositoryIdsToAdd = repositoryIdsToAdd + self.repositoryIdsToRemove = repositoryIdsToRemove } - public func encode(to encoder: any Encoder) throws { - switch self { - case let .case1(value): - try value.encode(to: encoder) - case let .case2(value): - try value.encode(to: encoder) - } + public enum CodingKeys: String, CodingKey { + case repositoryIdsToAdd = "repository_ids_to_add" + case repositoryIdsToRemove = "repository_ids_to_remove" } } /// - Remark: Generated from `#/paths/organizations/{org}/dependabot/repository-access/PATCH/requestBody/content/application\/json`. From 104c36dd9004714cb82b1a9d77e11546732d6bb5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:26:05 +0000 Subject: [PATCH 06/17] Commit via running: make Sources/markdown --- Sources/markdown/Client.swift | 2 +- Sources/markdown/Types.swift | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Sources/markdown/Client.swift b/Sources/markdown/Client.swift index f86df8fee0..6936f56e92 100644 --- a/Sources/markdown/Client.swift +++ b/Sources/markdown/Client.swift @@ -40,7 +40,7 @@ public struct Client: APIProtocol { } /// Render a Markdown document /// - /// + /// Depending on what is rendered in the Markdown, you may need to provide additional token scopes for labels, such as `issues:read` or `pull_requests:read`. /// /// - Remark: HTTP `POST /markdown`. /// - Remark: Generated from `#/paths//markdown/post(markdown/render)`. diff --git a/Sources/markdown/Types.swift b/Sources/markdown/Types.swift index 10f4f12ac1..e6f7824d76 100644 --- a/Sources/markdown/Types.swift +++ b/Sources/markdown/Types.swift @@ -13,7 +13,7 @@ import struct Foundation.Date public protocol APIProtocol: Sendable { /// Render a Markdown document /// - /// + /// Depending on what is rendered in the Markdown, you may need to provide additional token scopes for labels, such as `issues:read` or `pull_requests:read`. /// /// - Remark: HTTP `POST /markdown`. /// - Remark: Generated from `#/paths//markdown/post(markdown/render)`. @@ -31,7 +31,7 @@ public protocol APIProtocol: Sendable { extension APIProtocol { /// Render a Markdown document /// - /// + /// Depending on what is rendered in the Markdown, you may need to provide additional token scopes for labels, such as `issues:read` or `pull_requests:read`. /// /// - Remark: HTTP `POST /markdown`. /// - Remark: Generated from `#/paths//markdown/post(markdown/render)`. @@ -108,7 +108,7 @@ public enum Components { public enum Operations { /// Render a Markdown document /// - /// + /// Depending on what is rendered in the Markdown, you may need to provide additional token scopes for labels, such as `issues:read` or `pull_requests:read`. /// /// - Remark: HTTP `POST /markdown`. /// - Remark: Generated from `#/paths//markdown/post(markdown/render)`. From 7c8690f6dfc6579a6cb58b5670faf21efcb56329 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:27:19 +0000 Subject: [PATCH 07/17] Commit via running: make Sources/migrations --- Sources/migrations/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/migrations/Types.swift b/Sources/migrations/Types.swift index ca9deee7cc..7f00fc0ad5 100644 --- a/Sources/migrations/Types.swift +++ b/Sources/migrations/Types.swift @@ -2556,6 +2556,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -2646,6 +2670,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -2733,7 +2758,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -2822,6 +2848,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -2911,6 +2938,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// A migration. From 5002cdb0584682fe94ebe28e69196ab7d5d9b5da Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:28:08 +0000 Subject: [PATCH 08/17] Commit via running: make Sources/orgs --- Sources/orgs/Client.swift | 98 +++++++ Sources/orgs/Types.swift | 519 +++++++++++++++++++++++++++++++++++++- 2 files changed, 616 insertions(+), 1 deletion(-) diff --git a/Sources/orgs/Client.swift b/Sources/orgs/Client.swift index aea79cd7d8..102c00290f 100644 --- a/Sources/orgs/Client.swift +++ b/Sources/orgs/Client.swift @@ -464,6 +464,104 @@ public struct Client: APIProtocol { } ) } + /// List attestations by bulk subject digests + /// + /// List a collection of artifact attestations associated with any entry in a list of subject digests owned by an organization. + /// + /// The collection of attestations returned by this endpoint is filtered according to the authenticated user's permissions; if the authenticated user cannot read a repository, the attestations associated with that repository will not be included in the response. In addition, when using a fine-grained access token the `attestations:read` permission is required. + /// + /// **Please note:** in order to offer meaningful security benefits, an attestation's signature and timestamps **must** be cryptographically verified, and the identity of the attestation signer **must** be validated. Attestations can be verified using the [GitHub CLI `attestation verify` command](https://cli.github.com/manual/gh_attestation_verify). For more information, see [our guide on how to use artifact attestations to establish a build's provenance](https://docs.github.com/actions/security-guides/using-artifact-attestations-to-establish-provenance-for-builds). + /// + /// - Remark: HTTP `POST /orgs/{org}/attestations/bulk-list`. + /// - Remark: Generated from `#/paths//orgs/{org}/attestations/bulk-list/post(orgs/list-attestations-bulk)`. + public func orgsListAttestationsBulk(_ input: Operations.OrgsListAttestationsBulk.Input) async throws -> Operations.OrgsListAttestationsBulk.Output { + try await client.send( + input: input, + forOperation: Operations.OrgsListAttestationsBulk.id, + serializer: { input in + let path = try converter.renderedPath( + template: "/orgs/{}/attestations/bulk-list", + parameters: [ + input.path.org + ] + ) + var request: HTTPTypes.HTTPRequest = .init( + soar_path: path, + method: .post + ) + suppressMutabilityWarning(&request) + try converter.setQueryItemAsURI( + in: &request, + style: .form, + explode: true, + name: "per_page", + value: input.query.perPage + ) + try converter.setQueryItemAsURI( + in: &request, + style: .form, + explode: true, + name: "before", + value: input.query.before + ) + try converter.setQueryItemAsURI( + in: &request, + style: .form, + explode: true, + name: "after", + value: input.query.after + ) + converter.setAcceptHeader( + in: &request.headerFields, + contentTypes: input.headers.accept + ) + let body: OpenAPIRuntime.HTTPBody? + switch input.body { + case let .json(value): + body = try converter.setRequiredRequestBodyAsJSON( + value, + headerFields: &request.headerFields, + contentType: "application/json; charset=utf-8" + ) + } + return (request, body) + }, + deserializer: { response, responseBody in + switch response.status.code { + case 200: + let contentType = converter.extractContentTypeIfPresent(in: response.headerFields) + let body: Operations.OrgsListAttestationsBulk.Output.Ok.Body + let chosenContentType = try converter.bestContentType( + received: contentType, + options: [ + "application/json" + ] + ) + switch chosenContentType { + case "application/json": + body = try await converter.getResponseBodyAsJSON( + Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.self, + from: responseBody, + transforming: { value in + .json(value) + } + ) + default: + preconditionFailure("bestContentType chose an invalid content type.") + } + return .ok(.init(body: body)) + default: + return .undocumented( + statusCode: response.status.code, + .init( + headerFields: response.headerFields, + body: responseBody + ) + ) + } + } + ) + } /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by an organization. diff --git a/Sources/orgs/Types.swift b/Sources/orgs/Types.swift index a540655a4b..4ebbd92be7 100644 --- a/Sources/orgs/Types.swift +++ b/Sources/orgs/Types.swift @@ -66,6 +66,17 @@ public protocol APIProtocol: Sendable { /// - Remark: HTTP `DELETE /orgs/{org}`. /// - Remark: Generated from `#/paths//orgs/{org}/delete(orgs/delete)`. func orgsDelete(_ input: Operations.OrgsDelete.Input) async throws -> Operations.OrgsDelete.Output + /// List attestations by bulk subject digests + /// + /// List a collection of artifact attestations associated with any entry in a list of subject digests owned by an organization. + /// + /// The collection of attestations returned by this endpoint is filtered according to the authenticated user's permissions; if the authenticated user cannot read a repository, the attestations associated with that repository will not be included in the response. In addition, when using a fine-grained access token the `attestations:read` permission is required. + /// + /// **Please note:** in order to offer meaningful security benefits, an attestation's signature and timestamps **must** be cryptographically verified, and the identity of the attestation signer **must** be validated. Attestations can be verified using the [GitHub CLI `attestation verify` command](https://cli.github.com/manual/gh_attestation_verify). For more information, see [our guide on how to use artifact attestations to establish a build's provenance](https://docs.github.com/actions/security-guides/using-artifact-attestations-to-establish-provenance-for-builds). + /// + /// - Remark: HTTP `POST /orgs/{org}/attestations/bulk-list`. + /// - Remark: Generated from `#/paths//orgs/{org}/attestations/bulk-list/post(orgs/list-attestations-bulk)`. + func orgsListAttestationsBulk(_ input: Operations.OrgsListAttestationsBulk.Input) async throws -> Operations.OrgsListAttestationsBulk.Output /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by an organization. @@ -963,6 +974,29 @@ extension APIProtocol { headers: headers )) } + /// List attestations by bulk subject digests + /// + /// List a collection of artifact attestations associated with any entry in a list of subject digests owned by an organization. + /// + /// The collection of attestations returned by this endpoint is filtered according to the authenticated user's permissions; if the authenticated user cannot read a repository, the attestations associated with that repository will not be included in the response. In addition, when using a fine-grained access token the `attestations:read` permission is required. + /// + /// **Please note:** in order to offer meaningful security benefits, an attestation's signature and timestamps **must** be cryptographically verified, and the identity of the attestation signer **must** be validated. Attestations can be verified using the [GitHub CLI `attestation verify` command](https://cli.github.com/manual/gh_attestation_verify). For more information, see [our guide on how to use artifact attestations to establish a build's provenance](https://docs.github.com/actions/security-guides/using-artifact-attestations-to-establish-provenance-for-builds). + /// + /// - Remark: HTTP `POST /orgs/{org}/attestations/bulk-list`. + /// - Remark: Generated from `#/paths//orgs/{org}/attestations/bulk-list/post(orgs/list-attestations-bulk)`. + public func orgsListAttestationsBulk( + path: Operations.OrgsListAttestationsBulk.Input.Path, + query: Operations.OrgsListAttestationsBulk.Input.Query = .init(), + headers: Operations.OrgsListAttestationsBulk.Input.Headers = .init(), + body: Operations.OrgsListAttestationsBulk.Input.Body + ) async throws -> Operations.OrgsListAttestationsBulk.Output { + try await orgsListAttestationsBulk(Operations.OrgsListAttestationsBulk.Input( + path: path, + query: query, + headers: headers, + body: body + )) + } /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by an organization. @@ -5053,6 +5087,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -5143,6 +5201,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -5230,7 +5289,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -5319,6 +5379,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -5408,6 +5469,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// A GitHub organization. @@ -5614,6 +5676,10 @@ public enum Components { public var plan: Components.Schemas.OrganizationFull.PlanPayload? /// - Remark: Generated from `#/components/schemas/organization-full/default_repository_permission`. public var defaultRepositoryPermission: Swift.String? + /// The default branch for repositories created in this organization. + /// + /// - Remark: Generated from `#/components/schemas/organization-full/default_repository_branch`. + public var defaultRepositoryBranch: Swift.String? /// - Remark: Generated from `#/components/schemas/organization-full/members_can_create_repositories`. public var membersCanCreateRepositories: Swift.Bool? /// - Remark: Generated from `#/components/schemas/organization-full/two_factor_requirement_enabled`. @@ -5632,6 +5698,22 @@ public enum Components { public var membersCanCreatePublicPages: Swift.Bool? /// - Remark: Generated from `#/components/schemas/organization-full/members_can_create_private_pages`. public var membersCanCreatePrivatePages: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/members_can_delete_repositories`. + public var membersCanDeleteRepositories: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/members_can_change_repo_visibility`. + public var membersCanChangeRepoVisibility: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/members_can_invite_outside_collaborators`. + public var membersCanInviteOutsideCollaborators: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/members_can_delete_issues`. + public var membersCanDeleteIssues: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/display_commenter_full_name_setting_enabled`. + public var displayCommenterFullNameSettingEnabled: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/readers_can_create_discussions`. + public var readersCanCreateDiscussions: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/members_can_create_teams`. + public var membersCanCreateTeams: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-full/members_can_view_dependency_insights`. + public var membersCanViewDependencyInsights: Swift.Bool? /// - Remark: Generated from `#/components/schemas/organization-full/members_can_fork_private_repositories`. public var membersCanForkPrivateRepositories: Swift.Bool? /// - Remark: Generated from `#/components/schemas/organization-full/web_commit_signoff_required`. @@ -5746,6 +5828,7 @@ public enum Components { /// - billingEmail: /// - plan: /// - defaultRepositoryPermission: + /// - defaultRepositoryBranch: The default branch for repositories created in this organization. /// - membersCanCreateRepositories: /// - twoFactorRequirementEnabled: /// - membersAllowedRepositoryCreationType: @@ -5755,6 +5838,14 @@ public enum Components { /// - membersCanCreatePages: /// - membersCanCreatePublicPages: /// - membersCanCreatePrivatePages: + /// - membersCanDeleteRepositories: + /// - membersCanChangeRepoVisibility: + /// - membersCanInviteOutsideCollaborators: + /// - membersCanDeleteIssues: + /// - displayCommenterFullNameSettingEnabled: + /// - readersCanCreateDiscussions: + /// - membersCanCreateTeams: + /// - membersCanViewDependencyInsights: /// - membersCanForkPrivateRepositories: /// - webCommitSignoffRequired: /// - advancedSecurityEnabledForNewRepositories: **Endpoint closing down notice.** Please use [code security configurations](https://docs.github.com/rest/code-security/configurations) instead. @@ -5805,6 +5896,7 @@ public enum Components { billingEmail: Swift.String? = nil, plan: Components.Schemas.OrganizationFull.PlanPayload? = nil, defaultRepositoryPermission: Swift.String? = nil, + defaultRepositoryBranch: Swift.String? = nil, membersCanCreateRepositories: Swift.Bool? = nil, twoFactorRequirementEnabled: Swift.Bool? = nil, membersAllowedRepositoryCreationType: Swift.String? = nil, @@ -5814,6 +5906,14 @@ public enum Components { membersCanCreatePages: Swift.Bool? = nil, membersCanCreatePublicPages: Swift.Bool? = nil, membersCanCreatePrivatePages: Swift.Bool? = nil, + membersCanDeleteRepositories: Swift.Bool? = nil, + membersCanChangeRepoVisibility: Swift.Bool? = nil, + membersCanInviteOutsideCollaborators: Swift.Bool? = nil, + membersCanDeleteIssues: Swift.Bool? = nil, + displayCommenterFullNameSettingEnabled: Swift.Bool? = nil, + readersCanCreateDiscussions: Swift.Bool? = nil, + membersCanCreateTeams: Swift.Bool? = nil, + membersCanViewDependencyInsights: Swift.Bool? = nil, membersCanForkPrivateRepositories: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, advancedSecurityEnabledForNewRepositories: Swift.Bool? = nil, @@ -5864,6 +5964,7 @@ public enum Components { self.billingEmail = billingEmail self.plan = plan self.defaultRepositoryPermission = defaultRepositoryPermission + self.defaultRepositoryBranch = defaultRepositoryBranch self.membersCanCreateRepositories = membersCanCreateRepositories self.twoFactorRequirementEnabled = twoFactorRequirementEnabled self.membersAllowedRepositoryCreationType = membersAllowedRepositoryCreationType @@ -5873,6 +5974,14 @@ public enum Components { self.membersCanCreatePages = membersCanCreatePages self.membersCanCreatePublicPages = membersCanCreatePublicPages self.membersCanCreatePrivatePages = membersCanCreatePrivatePages + self.membersCanDeleteRepositories = membersCanDeleteRepositories + self.membersCanChangeRepoVisibility = membersCanChangeRepoVisibility + self.membersCanInviteOutsideCollaborators = membersCanInviteOutsideCollaborators + self.membersCanDeleteIssues = membersCanDeleteIssues + self.displayCommenterFullNameSettingEnabled = displayCommenterFullNameSettingEnabled + self.readersCanCreateDiscussions = readersCanCreateDiscussions + self.membersCanCreateTeams = membersCanCreateTeams + self.membersCanViewDependencyInsights = membersCanViewDependencyInsights self.membersCanForkPrivateRepositories = membersCanForkPrivateRepositories self.webCommitSignoffRequired = webCommitSignoffRequired self.advancedSecurityEnabledForNewRepositories = advancedSecurityEnabledForNewRepositories @@ -5924,6 +6033,7 @@ public enum Components { case billingEmail = "billing_email" case plan case defaultRepositoryPermission = "default_repository_permission" + case defaultRepositoryBranch = "default_repository_branch" case membersCanCreateRepositories = "members_can_create_repositories" case twoFactorRequirementEnabled = "two_factor_requirement_enabled" case membersAllowedRepositoryCreationType = "members_allowed_repository_creation_type" @@ -5933,6 +6043,14 @@ public enum Components { case membersCanCreatePages = "members_can_create_pages" case membersCanCreatePublicPages = "members_can_create_public_pages" case membersCanCreatePrivatePages = "members_can_create_private_pages" + case membersCanDeleteRepositories = "members_can_delete_repositories" + case membersCanChangeRepoVisibility = "members_can_change_repo_visibility" + case membersCanInviteOutsideCollaborators = "members_can_invite_outside_collaborators" + case membersCanDeleteIssues = "members_can_delete_issues" + case displayCommenterFullNameSettingEnabled = "display_commenter_full_name_setting_enabled" + case readersCanCreateDiscussions = "readers_can_create_discussions" + case membersCanCreateTeams = "members_can_create_teams" + case membersCanViewDependencyInsights = "members_can_view_dependency_insights" case membersCanForkPrivateRepositories = "members_can_fork_private_repositories" case webCommitSignoffRequired = "web_commit_signoff_required" case advancedSecurityEnabledForNewRepositories = "advanced_security_enabled_for_new_repositories" @@ -9807,6 +9925,405 @@ public enum Operations { } } } + /// List attestations by bulk subject digests + /// + /// List a collection of artifact attestations associated with any entry in a list of subject digests owned by an organization. + /// + /// The collection of attestations returned by this endpoint is filtered according to the authenticated user's permissions; if the authenticated user cannot read a repository, the attestations associated with that repository will not be included in the response. In addition, when using a fine-grained access token the `attestations:read` permission is required. + /// + /// **Please note:** in order to offer meaningful security benefits, an attestation's signature and timestamps **must** be cryptographically verified, and the identity of the attestation signer **must** be validated. Attestations can be verified using the [GitHub CLI `attestation verify` command](https://cli.github.com/manual/gh_attestation_verify). For more information, see [our guide on how to use artifact attestations to establish a build's provenance](https://docs.github.com/actions/security-guides/using-artifact-attestations-to-establish-provenance-for-builds). + /// + /// - Remark: HTTP `POST /orgs/{org}/attestations/bulk-list`. + /// - Remark: Generated from `#/paths//orgs/{org}/attestations/bulk-list/post(orgs/list-attestations-bulk)`. + public enum OrgsListAttestationsBulk { + public static let id: Swift.String = "orgs/list-attestations-bulk" + public struct Input: Sendable, Hashable { + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/path`. + public struct Path: Sendable, Hashable { + /// The organization name. The name is not case sensitive. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/path/org`. + public var org: Components.Parameters.Org + /// Creates a new `Path`. + /// + /// - Parameters: + /// - org: The organization name. The name is not case sensitive. + public init(org: Components.Parameters.Org) { + self.org = org + } + } + public var path: Operations.OrgsListAttestationsBulk.Input.Path + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/query`. + public struct Query: Sendable, Hashable { + /// The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/query/per_page`. + public var perPage: Components.Parameters.PerPage? + /// A cursor, as given in the [Link header](https://docs.github.com/rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/query/before`. + public var before: Components.Parameters.PaginationBefore? + /// A cursor, as given in the [Link header](https://docs.github.com/rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/query/after`. + public var after: Components.Parameters.PaginationAfter? + /// Creates a new `Query`. + /// + /// - Parameters: + /// - perPage: The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." + /// - before: A cursor, as given in the [Link header](https://docs.github.com/rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." + /// - after: A cursor, as given in the [Link header](https://docs.github.com/rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." + public init( + perPage: Components.Parameters.PerPage? = nil, + before: Components.Parameters.PaginationBefore? = nil, + after: Components.Parameters.PaginationAfter? = nil + ) { + self.perPage = perPage + self.before = before + self.after = after + } + } + public var query: Operations.OrgsListAttestationsBulk.Input.Query + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/header`. + public struct Headers: Sendable, Hashable { + public var accept: [OpenAPIRuntime.AcceptHeaderContentType] + /// Creates a new `Headers`. + /// + /// - Parameters: + /// - accept: + public init(accept: [OpenAPIRuntime.AcceptHeaderContentType] = .defaultValues()) { + self.accept = accept + } + } + public var headers: Operations.OrgsListAttestationsBulk.Input.Headers + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/requestBody`. + @frozen public enum Body: Sendable, Hashable { + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/requestBody/json`. + public struct JsonPayload: Codable, Hashable, Sendable { + /// List of subject digests to fetch attestations for. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/requestBody/json/subject_digests`. + public var subjectDigests: [Swift.String] + /// Optional filter for fetching attestations with a given predicate type. + /// This option accepts `provenance`, `sbom`, or freeform text for custom predicate types. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/requestBody/json/predicate_type`. + public var predicateType: Swift.String? + /// Creates a new `JsonPayload`. + /// + /// - Parameters: + /// - subjectDigests: List of subject digests to fetch attestations for. + /// - predicateType: Optional filter for fetching attestations with a given predicate type. + public init( + subjectDigests: [Swift.String], + predicateType: Swift.String? = nil + ) { + self.subjectDigests = subjectDigests + self.predicateType = predicateType + } + public enum CodingKeys: String, CodingKey { + case subjectDigests = "subject_digests" + case predicateType = "predicate_type" + } + } + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/requestBody/content/application\/json`. + case json(Operations.OrgsListAttestationsBulk.Input.Body.JsonPayload) + } + public var body: Operations.OrgsListAttestationsBulk.Input.Body + /// Creates a new `Input`. + /// + /// - Parameters: + /// - path: + /// - query: + /// - headers: + /// - body: + public init( + path: Operations.OrgsListAttestationsBulk.Input.Path, + query: Operations.OrgsListAttestationsBulk.Input.Query = .init(), + headers: Operations.OrgsListAttestationsBulk.Input.Headers = .init(), + body: Operations.OrgsListAttestationsBulk.Input.Body + ) { + self.path = path + self.query = query + self.headers = headers + self.body = body + } + } + @frozen public enum Output: Sendable, Hashable { + public struct Ok: Sendable, Hashable { + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content`. + @frozen public enum Body: Sendable, Hashable { + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json`. + public struct JsonPayload: Codable, Hashable, Sendable { + /// Mapping of subject digest to bundles. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests`. + public struct AttestationsSubjectDigestsPayload: Codable, Hashable, Sendable { + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload`. + public struct AdditionalPropertiesPayloadPayload: Codable, Hashable, Sendable { + /// The bundle of the attestation. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle`. + public struct BundlePayload: Codable, Hashable, Sendable { + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle/mediaType`. + public var mediaType: Swift.String? + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle/verificationMaterial`. + public struct VerificationMaterialPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `VerificationMaterialPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle/verificationMaterial`. + public var verificationMaterial: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayloadPayload.BundlePayload.VerificationMaterialPayload? + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle/dsseEnvelope`. + public struct DsseEnvelopePayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `DsseEnvelopePayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle/dsseEnvelope`. + public var dsseEnvelope: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayloadPayload.BundlePayload.DsseEnvelopePayload? + /// Creates a new `BundlePayload`. + /// + /// - Parameters: + /// - mediaType: + /// - verificationMaterial: + /// - dsseEnvelope: + public init( + mediaType: Swift.String? = nil, + verificationMaterial: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayloadPayload.BundlePayload.VerificationMaterialPayload? = nil, + dsseEnvelope: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayloadPayload.BundlePayload.DsseEnvelopePayload? = nil + ) { + self.mediaType = mediaType + self.verificationMaterial = verificationMaterial + self.dsseEnvelope = dsseEnvelope + } + public enum CodingKeys: String, CodingKey { + case mediaType + case verificationMaterial + case dsseEnvelope + } + } + /// The bundle of the attestation. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle`. + public var bundle: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayloadPayload.BundlePayload? + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/repository_id`. + public var repositoryId: Swift.Int? + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/AdditionalPropertiesPayload/bundle_url`. + public var bundleUrl: Swift.String? + /// Creates a new `AdditionalPropertiesPayloadPayload`. + /// + /// - Parameters: + /// - bundle: The bundle of the attestation. + /// - repositoryId: + /// - bundleUrl: + public init( + bundle: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayloadPayload.BundlePayload? = nil, + repositoryId: Swift.Int? = nil, + bundleUrl: Swift.String? = nil + ) { + self.bundle = bundle + self.repositoryId = repositoryId + self.bundleUrl = bundleUrl + } + public enum CodingKeys: String, CodingKey { + case bundle + case repositoryId = "repository_id" + case bundleUrl = "bundle_url" + } + } + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests/additionalProperties`. + public typealias AdditionalPropertiesPayload = [Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayloadPayload] + /// A container of undocumented properties. + public var additionalProperties: [String: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayload?] + /// Creates a new `AttestationsSubjectDigestsPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: [String: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload.AdditionalPropertiesPayload?] = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// Mapping of subject digest to bundles. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/attestations_subject_digests`. + public var attestationsSubjectDigests: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload? + /// Information about the current page. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/page_info`. + public struct PageInfoPayload: Codable, Hashable, Sendable { + /// Indicates whether there is a next page. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/page_info/has_next`. + public var hasNext: Swift.Bool? + /// Indicates whether there is a previous page. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/page_info/has_previous`. + public var hasPrevious: Swift.Bool? + /// The cursor to the next page. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/page_info/next`. + public var next: Swift.String? + /// The cursor to the previous page. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/page_info/previous`. + public var previous: Swift.String? + /// Creates a new `PageInfoPayload`. + /// + /// - Parameters: + /// - hasNext: Indicates whether there is a next page. + /// - hasPrevious: Indicates whether there is a previous page. + /// - next: The cursor to the next page. + /// - previous: The cursor to the previous page. + public init( + hasNext: Swift.Bool? = nil, + hasPrevious: Swift.Bool? = nil, + next: Swift.String? = nil, + previous: Swift.String? = nil + ) { + self.hasNext = hasNext + self.hasPrevious = hasPrevious + self.next = next + self.previous = previous + } + public enum CodingKeys: String, CodingKey { + case hasNext = "has_next" + case hasPrevious = "has_previous" + case next + case previous + } + } + /// Information about the current page. + /// + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/json/page_info`. + public var pageInfo: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.PageInfoPayload? + /// Creates a new `JsonPayload`. + /// + /// - Parameters: + /// - attestationsSubjectDigests: Mapping of subject digest to bundles. + /// - pageInfo: Information about the current page. + public init( + attestationsSubjectDigests: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.AttestationsSubjectDigestsPayload? = nil, + pageInfo: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload.PageInfoPayload? = nil + ) { + self.attestationsSubjectDigests = attestationsSubjectDigests + self.pageInfo = pageInfo + } + public enum CodingKeys: String, CodingKey { + case attestationsSubjectDigests = "attestations_subject_digests" + case pageInfo = "page_info" + } + } + /// - Remark: Generated from `#/paths/orgs/{org}/attestations/bulk-list/POST/responses/200/content/application\/json`. + case json(Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload) + /// The associated value of the enum case if `self` is `.json`. + /// + /// - Throws: An error if `self` is not `.json`. + /// - SeeAlso: `.json`. + public var json: Operations.OrgsListAttestationsBulk.Output.Ok.Body.JsonPayload { + get throws { + switch self { + case let .json(body): + return body + } + } + } + } + /// Received HTTP response body + public var body: Operations.OrgsListAttestationsBulk.Output.Ok.Body + /// Creates a new `Ok`. + /// + /// - Parameters: + /// - body: Received HTTP response body + public init(body: Operations.OrgsListAttestationsBulk.Output.Ok.Body) { + self.body = body + } + } + /// Response + /// + /// - Remark: Generated from `#/paths//orgs/{org}/attestations/bulk-list/post(orgs/list-attestations-bulk)/responses/200`. + /// + /// HTTP response code: `200 ok`. + case ok(Operations.OrgsListAttestationsBulk.Output.Ok) + /// The associated value of the enum case if `self` is `.ok`. + /// + /// - Throws: An error if `self` is not `.ok`. + /// - SeeAlso: `.ok`. + public var ok: Operations.OrgsListAttestationsBulk.Output.Ok { + get throws { + switch self { + case let .ok(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "ok", + response: self + ) + } + } + } + /// Undocumented response. + /// + /// A response with a code that is not documented in the OpenAPI document. + case undocumented(statusCode: Swift.Int, OpenAPIRuntime.UndocumentedPayload) + } + @frozen public enum AcceptableContentType: AcceptableProtocol { + case json + case other(Swift.String) + public init?(rawValue: Swift.String) { + switch rawValue.lowercased() { + case "application/json": + self = .json + default: + self = .other(rawValue) + } + } + public var rawValue: Swift.String { + switch self { + case let .other(string): + return string + case .json: + return "application/json" + } + } + public static var allCases: [Self] { + [ + .json + ] + } + } + } /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by an organization. From fc272d85085d8871a6ef5413a1873f9dd1f1c11a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:28:32 +0000 Subject: [PATCH 09/17] Commit via running: make Sources/packages --- Sources/packages/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/packages/Types.swift b/Sources/packages/Types.swift index 99a71ce25d..a6ad90ac01 100644 --- a/Sources/packages/Types.swift +++ b/Sources/packages/Types.swift @@ -1667,6 +1667,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/nullable-minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/nullable-minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/nullable-minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.NullableMinimalRepository.CustomPropertiesPayload? /// Creates a new `NullableMinimalRepository`. /// /// - Parameters: @@ -1757,6 +1781,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -1844,7 +1869,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.NullableMinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -1933,6 +1959,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -2022,6 +2049,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// A software package From c5d09f1114c326ad5445d83c608e807698c80667 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:29:21 +0000 Subject: [PATCH 10/17] Commit via running: make Sources/pulls --- Sources/pulls/Types.swift | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/Sources/pulls/Types.swift b/Sources/pulls/Types.swift index aa7776b7e8..dcfdba5b3b 100644 --- a/Sources/pulls/Types.swift +++ b/Sources/pulls/Types.swift @@ -5039,6 +5039,17 @@ public enum Components { /// /// - Remark: Generated from `#/components/schemas/review-comment/original_start_line`. public var originalStartLine: Swift.Int? + /// The level at which the comment is targeted, can be a diff line or a file. + /// + /// - Remark: Generated from `#/components/schemas/review-comment/subject_type`. + @frozen public enum SubjectTypePayload: String, Codable, Hashable, Sendable, CaseIterable { + case line = "line" + case file = "file" + } + /// The level at which the comment is targeted, can be a diff line or a file. + /// + /// - Remark: Generated from `#/components/schemas/review-comment/subject_type`. + public var subjectType: Components.Schemas.ReviewComment.SubjectTypePayload? /// Creates a new `ReviewComment`. /// /// - Parameters: @@ -5070,6 +5081,7 @@ public enum Components { /// - originalLine: The original line of the blob to which the comment applies. The last line of the range for a multi-line comment /// - startLine: The first line of the range for a multi-line comment. /// - originalStartLine: The original first line of the range for a multi-line comment. + /// - subjectType: The level at which the comment is targeted, can be a diff line or a file. public init( url: Swift.String, pullRequestReviewId: Swift.Int64? = nil, @@ -5098,7 +5110,8 @@ public enum Components { line: Swift.Int? = nil, originalLine: Swift.Int? = nil, startLine: Swift.Int? = nil, - originalStartLine: Swift.Int? = nil + originalStartLine: Swift.Int? = nil, + subjectType: Components.Schemas.ReviewComment.SubjectTypePayload? = nil ) { self.url = url self.pullRequestReviewId = pullRequestReviewId @@ -5128,6 +5141,7 @@ public enum Components { self.originalLine = originalLine self.startLine = startLine self.originalStartLine = originalStartLine + self.subjectType = subjectType } public enum CodingKeys: String, CodingKey { case url @@ -5158,6 +5172,7 @@ public enum Components { case originalLine = "original_line" case startLine = "start_line" case originalStartLine = "original_start_line" + case subjectType = "subject_type" } } } From 99b6a78628048de3d6e74265da8c7f1070fb2660 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:30:36 +0000 Subject: [PATCH 11/17] Commit via running: make Sources/repos --- Sources/repos/Types.swift | 46 +++++++++++++++++++++++++++++++-------- 1 file changed, 37 insertions(+), 9 deletions(-) diff --git a/Sources/repos/Types.swift b/Sources/repos/Types.swift index 04af42f57c..60d793b703 100644 --- a/Sources/repos/Types.swift +++ b/Sources/repos/Types.swift @@ -9029,6 +9029,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -9119,6 +9143,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -9206,7 +9231,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -9295,6 +9321,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -9384,6 +9411,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// An object without any properties. @@ -22799,7 +22827,7 @@ public enum Components { public typealias RepositoryNameInQuery = Swift.String /// The time period to filter by. /// - /// For example, `day` will filter for rule suites that occurred in the past 24 hours, and `week` will filter for insights that occurred in the past 7 days (168 hours). + /// For example, `day` will filter for rule suites that occurred in the past 24 hours, and `week` will filter for rule suites that occurred in the past 7 days (168 hours). /// /// - Remark: Generated from `#/components/parameters/time-period`. @frozen public enum TimePeriod: String, Codable, Hashable, Sendable, CaseIterable { @@ -22812,7 +22840,7 @@ public enum Components { /// /// - Remark: Generated from `#/components/parameters/actor-name-in-query`. public typealias ActorNameInQuery = Swift.String - /// The rule results to filter on. When specified, only suites with this result will be returned. + /// The rule suite results to filter on. When specified, only suites with this result will be returned. /// /// - Remark: Generated from `#/components/parameters/rule-suite-result`. @frozen public enum RuleSuiteResult: String, Codable, Hashable, Sendable, CaseIterable { @@ -24594,7 +24622,7 @@ public enum Operations { } /// The time period to filter by. /// - /// For example, `day` will filter for rule suites that occurred in the past 24 hours, and `week` will filter for insights that occurred in the past 7 days (168 hours). + /// For example, `day` will filter for rule suites that occurred in the past 24 hours, and `week` will filter for rule suites that occurred in the past 7 days (168 hours). /// /// - Remark: Generated from `#/paths/orgs/{org}/rulesets/rule-suites/GET/query/time_period`. public var timePeriod: Components.Parameters.TimePeriod? @@ -24609,7 +24637,7 @@ public enum Operations { case bypass = "bypass" case all = "all" } - /// The rule results to filter on. When specified, only suites with this result will be returned. + /// The rule suite results to filter on. When specified, only suites with this result will be returned. /// /// - Remark: Generated from `#/paths/orgs/{org}/rulesets/rule-suites/GET/query/rule_suite_result`. public var ruleSuiteResult: Components.Parameters.RuleSuiteResult? @@ -24628,7 +24656,7 @@ public enum Operations { /// - repositoryName: The name of the repository to filter on. /// - timePeriod: The time period to filter by. /// - actorName: The handle for the GitHub user account to filter on. When specified, only rule evaluations triggered by this actor will be returned. - /// - ruleSuiteResult: The rule results to filter on. When specified, only suites with this result will be returned. + /// - ruleSuiteResult: The rule suite results to filter on. When specified, only suites with this result will be returned. /// - perPage: The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." /// - page: The page number of the results to fetch. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." public init( @@ -58293,7 +58321,7 @@ public enum Operations { } /// The time period to filter by. /// - /// For example, `day` will filter for rule suites that occurred in the past 24 hours, and `week` will filter for insights that occurred in the past 7 days (168 hours). + /// For example, `day` will filter for rule suites that occurred in the past 24 hours, and `week` will filter for rule suites that occurred in the past 7 days (168 hours). /// /// - Remark: Generated from `#/paths/repos/{owner}/{repo}/rulesets/rule-suites/GET/query/time_period`. public var timePeriod: Components.Parameters.TimePeriod? @@ -58308,7 +58336,7 @@ public enum Operations { case bypass = "bypass" case all = "all" } - /// The rule results to filter on. When specified, only suites with this result will be returned. + /// The rule suite results to filter on. When specified, only suites with this result will be returned. /// /// - Remark: Generated from `#/paths/repos/{owner}/{repo}/rulesets/rule-suites/GET/query/rule_suite_result`. public var ruleSuiteResult: Components.Parameters.RuleSuiteResult? @@ -58326,7 +58354,7 @@ public enum Operations { /// - ref: The name of the ref. Cannot contain wildcard characters. Optionally prefix with `refs/heads/` to limit to branches or `refs/tags/` to limit to tags. Omit the prefix to search across all refs. When specified, only rule evaluations triggered for this ref will be returned. /// - timePeriod: The time period to filter by. /// - actorName: The handle for the GitHub user account to filter on. When specified, only rule evaluations triggered by this actor will be returned. - /// - ruleSuiteResult: The rule results to filter on. When specified, only suites with this result will be returned. + /// - ruleSuiteResult: The rule suite results to filter on. When specified, only suites with this result will be returned. /// - perPage: The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." /// - page: The page number of the results to fetch. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)." public init( From 990980be10bbad167ef1b423aaa3526f4d67b9e7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:31:00 +0000 Subject: [PATCH 12/17] Commit via running: make Sources/search --- Sources/search/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/search/Types.swift b/Sources/search/Types.swift index 7821b0f6b6..87e5247004 100644 --- a/Sources/search/Types.swift +++ b/Sources/search/Types.swift @@ -2725,6 +2725,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -2815,6 +2839,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -2902,7 +2927,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -2991,6 +3017,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -3080,6 +3107,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// Metaproperties for Git author/committer information. From 2b3bbc3451d407aae353231919f4b05d38009e05 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:31:24 +0000 Subject: [PATCH 13/17] Commit via running: make Sources/secret-scanning --- Sources/secret-scanning/Types.swift | 1428 +++++++++++++++------------ 1 file changed, 802 insertions(+), 626 deletions(-) diff --git a/Sources/secret-scanning/Types.swift b/Sources/secret-scanning/Types.swift index d0ab55c5b1..2028f41043 100644 --- a/Sources/secret-scanning/Types.swift +++ b/Sources/secret-scanning/Types.swift @@ -1036,308 +1036,633 @@ public enum Components { case revoked = "revoked" case usedInTests = "used_in_tests" } - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert`. - public struct OrganizationSecretScanningAlert: Codable, Hashable, Sendable { - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/number`. - public var number: Components.Schemas.AlertNumber? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/created_at`. - public var createdAt: Components.Schemas.AlertCreatedAt? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/updated_at`. - public var updatedAt: Components.Schemas.NullableAlertUpdatedAt? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/url`. - public var url: Components.Schemas.AlertUrl? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/html_url`. - public var htmlUrl: Components.Schemas.AlertHtmlUrl? - /// The REST API URL of the code locations for this alert. + /// Represents a 'commit' secret scanning location type. This location type shows that a secret was detected inside a commit to a repository. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit`. + public struct SecretScanningLocationCommit: Codable, Hashable, Sendable { + /// The file path in the repository /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/locations_url`. - public var locationsUrl: Swift.String? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/state`. - public var state: Components.Schemas.SecretScanningAlertState? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolution`. - public var resolution: Components.Schemas.SecretScanningAlertResolution? - /// The time that the alert was resolved in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/path`. + public var path: Swift.String + /// Line number at which the secret starts in the file /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolved_at`. - public var resolvedAt: Foundation.Date? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolved_by`. - public var resolvedBy: Components.Schemas.NullableSimpleUser? - /// The type of secret that secret scanning detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/start_line`. + public var startLine: Swift.Double + /// Line number at which the secret ends in the file /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/secret_type`. - public var secretType: Swift.String? - /// User-friendly name for the detected secret, matching the `secret_type`. - /// For a list of built-in patterns, see "[Supported secret scanning patterns](https://docs.github.com/code-security/secret-scanning/introduction/supported-secret-scanning-patterns#supported-secrets)." + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/end_line`. + public var endLine: Swift.Double + /// The column at which the secret starts within the start line when the file is interpreted as 8BIT ASCII /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/secret_type_display_name`. - public var secretTypeDisplayName: Swift.String? - /// The secret that was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/start_column`. + public var startColumn: Swift.Double + /// The column at which the secret ends within the end line when the file is interpreted as 8BIT ASCII /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/secret`. - public var secret: Swift.String? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/repository`. - public var repository: Components.Schemas.SimpleRepository? - /// Whether push protection was bypassed for the detected secret. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/end_column`. + public var endColumn: Swift.Double + /// SHA-1 hash ID of the associated blob /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypassed`. - public var pushProtectionBypassed: Swift.Bool? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypassed_by`. - public var pushProtectionBypassedBy: Components.Schemas.NullableSimpleUser? - /// The time that push protection was bypassed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/blob_sha`. + public var blobSha: Swift.String + /// The API URL to get the associated blob resource /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypassed_at`. - public var pushProtectionBypassedAt: Foundation.Date? - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_reviewer`. - public var pushProtectionBypassRequestReviewer: Components.Schemas.NullableSimpleUser? - /// An optional comment when reviewing a push protection bypass. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/blob_url`. + public var blobUrl: Swift.String + /// SHA-1 hash ID of the associated commit /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_reviewer_comment`. - public var pushProtectionBypassRequestReviewerComment: Swift.String? - /// An optional comment when requesting a push protection bypass. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/commit_sha`. + public var commitSha: Swift.String + /// The API URL to get the associated commit resource /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_comment`. - public var pushProtectionBypassRequestComment: Swift.String? - /// The URL to a push protection bypass request. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/commit_url`. + public var commitUrl: Swift.String + /// Creates a new `SecretScanningLocationCommit`. /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_html_url`. - public var pushProtectionBypassRequestHtmlUrl: Swift.String? - /// The comment that was optionally added when this alert was closed + /// - Parameters: + /// - path: The file path in the repository + /// - startLine: Line number at which the secret starts in the file + /// - endLine: Line number at which the secret ends in the file + /// - startColumn: The column at which the secret starts within the start line when the file is interpreted as 8BIT ASCII + /// - endColumn: The column at which the secret ends within the end line when the file is interpreted as 8BIT ASCII + /// - blobSha: SHA-1 hash ID of the associated blob + /// - blobUrl: The API URL to get the associated blob resource + /// - commitSha: SHA-1 hash ID of the associated commit + /// - commitUrl: The API URL to get the associated commit resource + public init( + path: Swift.String, + startLine: Swift.Double, + endLine: Swift.Double, + startColumn: Swift.Double, + endColumn: Swift.Double, + blobSha: Swift.String, + blobUrl: Swift.String, + commitSha: Swift.String, + commitUrl: Swift.String + ) { + self.path = path + self.startLine = startLine + self.endLine = endLine + self.startColumn = startColumn + self.endColumn = endColumn + self.blobSha = blobSha + self.blobUrl = blobUrl + self.commitSha = commitSha + self.commitUrl = commitUrl + } + public enum CodingKeys: String, CodingKey { + case path + case startLine = "start_line" + case endLine = "end_line" + case startColumn = "start_column" + case endColumn = "end_column" + case blobSha = "blob_sha" + case blobUrl = "blob_url" + case commitSha = "commit_sha" + case commitUrl = "commit_url" + } + } + /// Represents a 'wiki_commit' secret scanning location type. This location type shows that a secret was detected inside a commit to a repository wiki. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit`. + public struct SecretScanningLocationWikiCommit: Codable, Hashable, Sendable { + /// The file path of the wiki page /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolution_comment`. - public var resolutionComment: Swift.String? - /// The token status as of the latest validity check. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/path`. + public var path: Swift.String + /// Line number at which the secret starts in the file /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/validity`. - @frozen public enum ValidityPayload: String, Codable, Hashable, Sendable, CaseIterable { - case active = "active" - case inactive = "inactive" - case unknown = "unknown" - } - /// The token status as of the latest validity check. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/start_line`. + public var startLine: Swift.Double + /// Line number at which the secret ends in the file /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/validity`. - public var validity: Components.Schemas.OrganizationSecretScanningAlert.ValidityPayload? - /// Whether the secret was publicly leaked. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/end_line`. + public var endLine: Swift.Double + /// The column at which the secret starts within the start line when the file is interpreted as 8-bit ASCII. /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/publicly_leaked`. - public var publiclyLeaked: Swift.Bool? - /// Whether the detected secret was found in multiple repositories in the same organization or enterprise. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/start_column`. + public var startColumn: Swift.Double + /// The column at which the secret ends within the end line when the file is interpreted as 8-bit ASCII. /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/multi_repo`. - public var multiRepo: Swift.Bool? - /// A boolean value representing whether or not alert is base64 encoded + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/end_column`. + public var endColumn: Swift.Double + /// SHA-1 hash ID of the associated blob /// - /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/is_base64_encoded`. - public var isBase64Encoded: Swift.Bool? - /// Creates a new `OrganizationSecretScanningAlert`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/blob_sha`. + public var blobSha: Swift.String + /// The GitHub URL to get the associated wiki page + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/page_url`. + public var pageUrl: Swift.String + /// SHA-1 hash ID of the associated commit + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/commit_sha`. + public var commitSha: Swift.String + /// The GitHub URL to get the associated wiki commit + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/commit_url`. + public var commitUrl: Swift.String + /// Creates a new `SecretScanningLocationWikiCommit`. /// /// - Parameters: - /// - number: - /// - createdAt: - /// - updatedAt: - /// - url: - /// - htmlUrl: - /// - locationsUrl: The REST API URL of the code locations for this alert. - /// - state: - /// - resolution: - /// - resolvedAt: The time that the alert was resolved in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. - /// - resolvedBy: - /// - secretType: The type of secret that secret scanning detected. - /// - secretTypeDisplayName: User-friendly name for the detected secret, matching the `secret_type`. - /// - secret: The secret that was detected. - /// - repository: - /// - pushProtectionBypassed: Whether push protection was bypassed for the detected secret. - /// - pushProtectionBypassedBy: - /// - pushProtectionBypassedAt: The time that push protection was bypassed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. - /// - pushProtectionBypassRequestReviewer: - /// - pushProtectionBypassRequestReviewerComment: An optional comment when reviewing a push protection bypass. - /// - pushProtectionBypassRequestComment: An optional comment when requesting a push protection bypass. - /// - pushProtectionBypassRequestHtmlUrl: The URL to a push protection bypass request. - /// - resolutionComment: The comment that was optionally added when this alert was closed - /// - validity: The token status as of the latest validity check. - /// - publiclyLeaked: Whether the secret was publicly leaked. - /// - multiRepo: Whether the detected secret was found in multiple repositories in the same organization or enterprise. - /// - isBase64Encoded: A boolean value representing whether or not alert is base64 encoded + /// - path: The file path of the wiki page + /// - startLine: Line number at which the secret starts in the file + /// - endLine: Line number at which the secret ends in the file + /// - startColumn: The column at which the secret starts within the start line when the file is interpreted as 8-bit ASCII. + /// - endColumn: The column at which the secret ends within the end line when the file is interpreted as 8-bit ASCII. + /// - blobSha: SHA-1 hash ID of the associated blob + /// - pageUrl: The GitHub URL to get the associated wiki page + /// - commitSha: SHA-1 hash ID of the associated commit + /// - commitUrl: The GitHub URL to get the associated wiki commit public init( - number: Components.Schemas.AlertNumber? = nil, - createdAt: Components.Schemas.AlertCreatedAt? = nil, - updatedAt: Components.Schemas.NullableAlertUpdatedAt? = nil, - url: Components.Schemas.AlertUrl? = nil, - htmlUrl: Components.Schemas.AlertHtmlUrl? = nil, - locationsUrl: Swift.String? = nil, - state: Components.Schemas.SecretScanningAlertState? = nil, - resolution: Components.Schemas.SecretScanningAlertResolution? = nil, - resolvedAt: Foundation.Date? = nil, - resolvedBy: Components.Schemas.NullableSimpleUser? = nil, - secretType: Swift.String? = nil, - secretTypeDisplayName: Swift.String? = nil, - secret: Swift.String? = nil, - repository: Components.Schemas.SimpleRepository? = nil, - pushProtectionBypassed: Swift.Bool? = nil, - pushProtectionBypassedBy: Components.Schemas.NullableSimpleUser? = nil, - pushProtectionBypassedAt: Foundation.Date? = nil, - pushProtectionBypassRequestReviewer: Components.Schemas.NullableSimpleUser? = nil, - pushProtectionBypassRequestReviewerComment: Swift.String? = nil, - pushProtectionBypassRequestComment: Swift.String? = nil, - pushProtectionBypassRequestHtmlUrl: Swift.String? = nil, - resolutionComment: Swift.String? = nil, - validity: Components.Schemas.OrganizationSecretScanningAlert.ValidityPayload? = nil, - publiclyLeaked: Swift.Bool? = nil, - multiRepo: Swift.Bool? = nil, - isBase64Encoded: Swift.Bool? = nil - ) { - self.number = number - self.createdAt = createdAt - self.updatedAt = updatedAt - self.url = url - self.htmlUrl = htmlUrl - self.locationsUrl = locationsUrl - self.state = state - self.resolution = resolution - self.resolvedAt = resolvedAt - self.resolvedBy = resolvedBy - self.secretType = secretType - self.secretTypeDisplayName = secretTypeDisplayName - self.secret = secret - self.repository = repository - self.pushProtectionBypassed = pushProtectionBypassed - self.pushProtectionBypassedBy = pushProtectionBypassedBy - self.pushProtectionBypassedAt = pushProtectionBypassedAt - self.pushProtectionBypassRequestReviewer = pushProtectionBypassRequestReviewer - self.pushProtectionBypassRequestReviewerComment = pushProtectionBypassRequestReviewerComment - self.pushProtectionBypassRequestComment = pushProtectionBypassRequestComment - self.pushProtectionBypassRequestHtmlUrl = pushProtectionBypassRequestHtmlUrl - self.resolutionComment = resolutionComment - self.validity = validity - self.publiclyLeaked = publiclyLeaked - self.multiRepo = multiRepo - self.isBase64Encoded = isBase64Encoded + path: Swift.String, + startLine: Swift.Double, + endLine: Swift.Double, + startColumn: Swift.Double, + endColumn: Swift.Double, + blobSha: Swift.String, + pageUrl: Swift.String, + commitSha: Swift.String, + commitUrl: Swift.String + ) { + self.path = path + self.startLine = startLine + self.endLine = endLine + self.startColumn = startColumn + self.endColumn = endColumn + self.blobSha = blobSha + self.pageUrl = pageUrl + self.commitSha = commitSha + self.commitUrl = commitUrl } public enum CodingKeys: String, CodingKey { - case number - case createdAt = "created_at" - case updatedAt = "updated_at" - case url - case htmlUrl = "html_url" - case locationsUrl = "locations_url" - case state - case resolution - case resolvedAt = "resolved_at" - case resolvedBy = "resolved_by" - case secretType = "secret_type" - case secretTypeDisplayName = "secret_type_display_name" - case secret - case repository - case pushProtectionBypassed = "push_protection_bypassed" - case pushProtectionBypassedBy = "push_protection_bypassed_by" - case pushProtectionBypassedAt = "push_protection_bypassed_at" - case pushProtectionBypassRequestReviewer = "push_protection_bypass_request_reviewer" - case pushProtectionBypassRequestReviewerComment = "push_protection_bypass_request_reviewer_comment" - case pushProtectionBypassRequestComment = "push_protection_bypass_request_comment" - case pushProtectionBypassRequestHtmlUrl = "push_protection_bypass_request_html_url" - case resolutionComment = "resolution_comment" - case validity - case publiclyLeaked = "publicly_leaked" - case multiRepo = "multi_repo" - case isBase64Encoded = "is_base64_encoded" + case path + case startLine = "start_line" + case endLine = "end_line" + case startColumn = "start_column" + case endColumn = "end_column" + case blobSha = "blob_sha" + case pageUrl = "page_url" + case commitSha = "commit_sha" + case commitUrl = "commit_url" } } - /// The ID of the push protection bypass placeholder. This value is returned on any push protected routes. + /// Represents an 'issue_title' secret scanning location type. This location type shows that a secret was detected in the title of an issue. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-push-protection-bypass-placeholder-id`. - public typealias SecretScanningPushProtectionBypassPlaceholderId = Swift.String - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert`. - public struct SecretScanningAlert: Codable, Hashable, Sendable { - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/number`. - public var number: Components.Schemas.AlertNumber? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/created_at`. - public var createdAt: Components.Schemas.AlertCreatedAt? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/updated_at`. - public var updatedAt: Components.Schemas.NullableAlertUpdatedAt? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/url`. - public var url: Components.Schemas.AlertUrl? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/html_url`. - public var htmlUrl: Components.Schemas.AlertHtmlUrl? - /// The REST API URL of the code locations for this alert. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-title`. + public struct SecretScanningLocationIssueTitle: Codable, Hashable, Sendable { + /// The API URL to get the issue where the secret was detected. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/locations_url`. - public var locationsUrl: Swift.String? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/state`. - public var state: Components.Schemas.SecretScanningAlertState? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolution`. - public var resolution: Components.Schemas.SecretScanningAlertResolution? - /// The time that the alert was resolved in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-title/issue_title_url`. + public var issueTitleUrl: Swift.String + /// Creates a new `SecretScanningLocationIssueTitle`. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolved_at`. - public var resolvedAt: Foundation.Date? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolved_by`. - public var resolvedBy: Components.Schemas.NullableSimpleUser? - /// An optional comment to resolve an alert. + /// - Parameters: + /// - issueTitleUrl: The API URL to get the issue where the secret was detected. + public init(issueTitleUrl: Swift.String) { + self.issueTitleUrl = issueTitleUrl + } + public enum CodingKeys: String, CodingKey { + case issueTitleUrl = "issue_title_url" + } + } + /// Represents an 'issue_body' secret scanning location type. This location type shows that a secret was detected in the body of an issue. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-body`. + public struct SecretScanningLocationIssueBody: Codable, Hashable, Sendable { + /// The API URL to get the issue where the secret was detected. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolution_comment`. - public var resolutionComment: Swift.String? - /// The type of secret that secret scanning detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-body/issue_body_url`. + public var issueBodyUrl: Swift.String + /// Creates a new `SecretScanningLocationIssueBody`. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/secret_type`. - public var secretType: Swift.String? - /// User-friendly name for the detected secret, matching the `secret_type`. - /// For a list of built-in patterns, see "[Supported secret scanning patterns](https://docs.github.com/code-security/secret-scanning/introduction/supported-secret-scanning-patterns#supported-secrets)." + /// - Parameters: + /// - issueBodyUrl: The API URL to get the issue where the secret was detected. + public init(issueBodyUrl: Swift.String) { + self.issueBodyUrl = issueBodyUrl + } + public enum CodingKeys: String, CodingKey { + case issueBodyUrl = "issue_body_url" + } + } + /// Represents an 'issue_comment' secret scanning location type. This location type shows that a secret was detected in a comment on an issue. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-comment`. + public struct SecretScanningLocationIssueComment: Codable, Hashable, Sendable { + /// The API URL to get the issue comment where the secret was detected. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/secret_type_display_name`. - public var secretTypeDisplayName: Swift.String? - /// The secret that was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-comment/issue_comment_url`. + public var issueCommentUrl: Swift.String + /// Creates a new `SecretScanningLocationIssueComment`. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/secret`. - public var secret: Swift.String? - /// Whether push protection was bypassed for the detected secret. + /// - Parameters: + /// - issueCommentUrl: The API URL to get the issue comment where the secret was detected. + public init(issueCommentUrl: Swift.String) { + self.issueCommentUrl = issueCommentUrl + } + public enum CodingKeys: String, CodingKey { + case issueCommentUrl = "issue_comment_url" + } + } + /// Represents a 'discussion_title' secret scanning location type. This location type shows that a secret was detected in the title of a discussion. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-title`. + public struct SecretScanningLocationDiscussionTitle: Codable, Hashable, Sendable { + /// The URL to the discussion where the secret was detected. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypassed`. - public var pushProtectionBypassed: Swift.Bool? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypassed_by`. - public var pushProtectionBypassedBy: Components.Schemas.NullableSimpleUser? - /// The time that push protection was bypassed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-title/discussion_title_url`. + public var discussionTitleUrl: Swift.String + /// Creates a new `SecretScanningLocationDiscussionTitle`. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypassed_at`. - public var pushProtectionBypassedAt: Foundation.Date? - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_reviewer`. - public var pushProtectionBypassRequestReviewer: Components.Schemas.NullableSimpleUser? - /// An optional comment when reviewing a push protection bypass. + /// - Parameters: + /// - discussionTitleUrl: The URL to the discussion where the secret was detected. + public init(discussionTitleUrl: Swift.String) { + self.discussionTitleUrl = discussionTitleUrl + } + public enum CodingKeys: String, CodingKey { + case discussionTitleUrl = "discussion_title_url" + } + } + /// Represents a 'discussion_body' secret scanning location type. This location type shows that a secret was detected in the body of a discussion. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-body`. + public struct SecretScanningLocationDiscussionBody: Codable, Hashable, Sendable { + /// The URL to the discussion where the secret was detected. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_reviewer_comment`. - public var pushProtectionBypassRequestReviewerComment: Swift.String? - /// An optional comment when requesting a push protection bypass. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-body/discussion_body_url`. + public var discussionBodyUrl: Swift.String + /// Creates a new `SecretScanningLocationDiscussionBody`. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_comment`. - public var pushProtectionBypassRequestComment: Swift.String? - /// The URL to a push protection bypass request. + /// - Parameters: + /// - discussionBodyUrl: The URL to the discussion where the secret was detected. + public init(discussionBodyUrl: Swift.String) { + self.discussionBodyUrl = discussionBodyUrl + } + public enum CodingKeys: String, CodingKey { + case discussionBodyUrl = "discussion_body_url" + } + } + /// Represents a 'discussion_comment' secret scanning location type. This location type shows that a secret was detected in a comment on a discussion. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-comment`. + public struct SecretScanningLocationDiscussionComment: Codable, Hashable, Sendable { + /// The API URL to get the discussion comment where the secret was detected. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_html_url`. - public var pushProtectionBypassRequestHtmlUrl: Swift.String? - /// The token status as of the latest validity check. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-comment/discussion_comment_url`. + public var discussionCommentUrl: Swift.String + /// Creates a new `SecretScanningLocationDiscussionComment`. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/validity`. - @frozen public enum ValidityPayload: String, Codable, Hashable, Sendable, CaseIterable { - case active = "active" - case inactive = "inactive" - case unknown = "unknown" + /// - Parameters: + /// - discussionCommentUrl: The API URL to get the discussion comment where the secret was detected. + public init(discussionCommentUrl: Swift.String) { + self.discussionCommentUrl = discussionCommentUrl } - /// The token status as of the latest validity check. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/validity`. - public var validity: Components.Schemas.SecretScanningAlert.ValidityPayload? - /// Whether the detected secret was publicly leaked. + public enum CodingKeys: String, CodingKey { + case discussionCommentUrl = "discussion_comment_url" + } + } + /// Represents a 'pull_request_title' secret scanning location type. This location type shows that a secret was detected in the title of a pull request. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-title`. + public struct SecretScanningLocationPullRequestTitle: Codable, Hashable, Sendable { + /// The API URL to get the pull request where the secret was detected. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/publicly_leaked`. - public var publiclyLeaked: Swift.Bool? - /// Whether the detected secret was found in multiple repositories under the same organization or enterprise. + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-title/pull_request_title_url`. + public var pullRequestTitleUrl: Swift.String + /// Creates a new `SecretScanningLocationPullRequestTitle`. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/multi_repo`. - public var multiRepo: Swift.Bool? + /// - Parameters: + /// - pullRequestTitleUrl: The API URL to get the pull request where the secret was detected. + public init(pullRequestTitleUrl: Swift.String) { + self.pullRequestTitleUrl = pullRequestTitleUrl + } + public enum CodingKeys: String, CodingKey { + case pullRequestTitleUrl = "pull_request_title_url" + } + } + /// Represents a 'pull_request_body' secret scanning location type. This location type shows that a secret was detected in the body of a pull request. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-body`. + public struct SecretScanningLocationPullRequestBody: Codable, Hashable, Sendable { + /// The API URL to get the pull request where the secret was detected. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-body/pull_request_body_url`. + public var pullRequestBodyUrl: Swift.String + /// Creates a new `SecretScanningLocationPullRequestBody`. + /// + /// - Parameters: + /// - pullRequestBodyUrl: The API URL to get the pull request where the secret was detected. + public init(pullRequestBodyUrl: Swift.String) { + self.pullRequestBodyUrl = pullRequestBodyUrl + } + public enum CodingKeys: String, CodingKey { + case pullRequestBodyUrl = "pull_request_body_url" + } + } + /// Represents a 'pull_request_comment' secret scanning location type. This location type shows that a secret was detected in a comment on a pull request. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-comment`. + public struct SecretScanningLocationPullRequestComment: Codable, Hashable, Sendable { + /// The API URL to get the pull request comment where the secret was detected. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-comment/pull_request_comment_url`. + public var pullRequestCommentUrl: Swift.String + /// Creates a new `SecretScanningLocationPullRequestComment`. + /// + /// - Parameters: + /// - pullRequestCommentUrl: The API URL to get the pull request comment where the secret was detected. + public init(pullRequestCommentUrl: Swift.String) { + self.pullRequestCommentUrl = pullRequestCommentUrl + } + public enum CodingKeys: String, CodingKey { + case pullRequestCommentUrl = "pull_request_comment_url" + } + } + /// Represents a 'pull_request_review' secret scanning location type. This location type shows that a secret was detected in a review on a pull request. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review`. + public struct SecretScanningLocationPullRequestReview: Codable, Hashable, Sendable { + /// The API URL to get the pull request review where the secret was detected. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review/pull_request_review_url`. + public var pullRequestReviewUrl: Swift.String + /// Creates a new `SecretScanningLocationPullRequestReview`. + /// + /// - Parameters: + /// - pullRequestReviewUrl: The API URL to get the pull request review where the secret was detected. + public init(pullRequestReviewUrl: Swift.String) { + self.pullRequestReviewUrl = pullRequestReviewUrl + } + public enum CodingKeys: String, CodingKey { + case pullRequestReviewUrl = "pull_request_review_url" + } + } + /// Represents a 'pull_request_review_comment' secret scanning location type. This location type shows that a secret was detected in a review comment on a pull request. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review-comment`. + public struct SecretScanningLocationPullRequestReviewComment: Codable, Hashable, Sendable { + /// The API URL to get the pull request review comment where the secret was detected. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review-comment/pull_request_review_comment_url`. + public var pullRequestReviewCommentUrl: Swift.String + /// Creates a new `SecretScanningLocationPullRequestReviewComment`. + /// + /// - Parameters: + /// - pullRequestReviewCommentUrl: The API URL to get the pull request review comment where the secret was detected. + public init(pullRequestReviewCommentUrl: Swift.String) { + self.pullRequestReviewCommentUrl = pullRequestReviewCommentUrl + } + public enum CodingKeys: String, CodingKey { + case pullRequestReviewCommentUrl = "pull_request_review_comment_url" + } + } + /// Details on the location where the token was initially detected. This can be a commit, wiki commit, issue, discussion, pull request. + /// + /// + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location`. + @frozen public enum NullableSecretScanningFirstDetectedLocation: Codable, Hashable, Sendable { + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case1`. + case SecretScanningLocationCommit(Components.Schemas.SecretScanningLocationCommit) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case2`. + case SecretScanningLocationWikiCommit(Components.Schemas.SecretScanningLocationWikiCommit) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case3`. + case SecretScanningLocationIssueTitle(Components.Schemas.SecretScanningLocationIssueTitle) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case4`. + case SecretScanningLocationIssueBody(Components.Schemas.SecretScanningLocationIssueBody) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case5`. + case SecretScanningLocationIssueComment(Components.Schemas.SecretScanningLocationIssueComment) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case6`. + case SecretScanningLocationDiscussionTitle(Components.Schemas.SecretScanningLocationDiscussionTitle) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case7`. + case SecretScanningLocationDiscussionBody(Components.Schemas.SecretScanningLocationDiscussionBody) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case8`. + case SecretScanningLocationDiscussionComment(Components.Schemas.SecretScanningLocationDiscussionComment) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case9`. + case SecretScanningLocationPullRequestTitle(Components.Schemas.SecretScanningLocationPullRequestTitle) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case10`. + case SecretScanningLocationPullRequestBody(Components.Schemas.SecretScanningLocationPullRequestBody) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case11`. + case SecretScanningLocationPullRequestComment(Components.Schemas.SecretScanningLocationPullRequestComment) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case12`. + case SecretScanningLocationPullRequestReview(Components.Schemas.SecretScanningLocationPullRequestReview) + /// - Remark: Generated from `#/components/schemas/nullable-secret-scanning-first-detected-location/case13`. + case SecretScanningLocationPullRequestReviewComment(Components.Schemas.SecretScanningLocationPullRequestReviewComment) + public init(from decoder: any Decoder) throws { + var errors: [any Error] = [] + do { + self = .SecretScanningLocationCommit(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationWikiCommit(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationIssueTitle(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationIssueBody(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationIssueComment(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationDiscussionTitle(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationDiscussionBody(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationDiscussionComment(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationPullRequestTitle(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationPullRequestBody(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationPullRequestComment(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationPullRequestReview(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .SecretScanningLocationPullRequestReviewComment(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + throw Swift.DecodingError.failedToDecodeOneOfSchema( + type: Self.self, + codingPath: decoder.codingPath, + errors: errors + ) + } + public func encode(to encoder: any Encoder) throws { + switch self { + case let .SecretScanningLocationCommit(value): + try value.encode(to: encoder) + case let .SecretScanningLocationWikiCommit(value): + try value.encode(to: encoder) + case let .SecretScanningLocationIssueTitle(value): + try value.encode(to: encoder) + case let .SecretScanningLocationIssueBody(value): + try value.encode(to: encoder) + case let .SecretScanningLocationIssueComment(value): + try value.encode(to: encoder) + case let .SecretScanningLocationDiscussionTitle(value): + try value.encode(to: encoder) + case let .SecretScanningLocationDiscussionBody(value): + try value.encode(to: encoder) + case let .SecretScanningLocationDiscussionComment(value): + try value.encode(to: encoder) + case let .SecretScanningLocationPullRequestTitle(value): + try value.encode(to: encoder) + case let .SecretScanningLocationPullRequestBody(value): + try value.encode(to: encoder) + case let .SecretScanningLocationPullRequestComment(value): + try value.encode(to: encoder) + case let .SecretScanningLocationPullRequestReview(value): + try value.encode(to: encoder) + case let .SecretScanningLocationPullRequestReviewComment(value): + try value.encode(to: encoder) + } + } + } + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert`. + public struct OrganizationSecretScanningAlert: Codable, Hashable, Sendable { + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/number`. + public var number: Components.Schemas.AlertNumber? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/created_at`. + public var createdAt: Components.Schemas.AlertCreatedAt? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/updated_at`. + public var updatedAt: Components.Schemas.NullableAlertUpdatedAt? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/url`. + public var url: Components.Schemas.AlertUrl? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/html_url`. + public var htmlUrl: Components.Schemas.AlertHtmlUrl? + /// The REST API URL of the code locations for this alert. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/locations_url`. + public var locationsUrl: Swift.String? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/state`. + public var state: Components.Schemas.SecretScanningAlertState? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolution`. + public var resolution: Components.Schemas.SecretScanningAlertResolution? + /// The time that the alert was resolved in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolved_at`. + public var resolvedAt: Foundation.Date? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolved_by`. + public var resolvedBy: Components.Schemas.NullableSimpleUser? + /// The type of secret that secret scanning detected. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/secret_type`. + public var secretType: Swift.String? + /// User-friendly name for the detected secret, matching the `secret_type`. + /// For a list of built-in patterns, see "[Supported secret scanning patterns](https://docs.github.com/code-security/secret-scanning/introduction/supported-secret-scanning-patterns#supported-secrets)." + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/secret_type_display_name`. + public var secretTypeDisplayName: Swift.String? + /// The secret that was detected. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/secret`. + public var secret: Swift.String? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/repository`. + public var repository: Components.Schemas.SimpleRepository? + /// Whether push protection was bypassed for the detected secret. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypassed`. + public var pushProtectionBypassed: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypassed_by`. + public var pushProtectionBypassedBy: Components.Schemas.NullableSimpleUser? + /// The time that push protection was bypassed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypassed_at`. + public var pushProtectionBypassedAt: Foundation.Date? + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_reviewer`. + public var pushProtectionBypassRequestReviewer: Components.Schemas.NullableSimpleUser? + /// An optional comment when reviewing a push protection bypass. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_reviewer_comment`. + public var pushProtectionBypassRequestReviewerComment: Swift.String? + /// An optional comment when requesting a push protection bypass. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_comment`. + public var pushProtectionBypassRequestComment: Swift.String? + /// The URL to a push protection bypass request. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/push_protection_bypass_request_html_url`. + public var pushProtectionBypassRequestHtmlUrl: Swift.String? + /// The comment that was optionally added when this alert was closed + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/resolution_comment`. + public var resolutionComment: Swift.String? + /// The token status as of the latest validity check. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/validity`. + @frozen public enum ValidityPayload: String, Codable, Hashable, Sendable, CaseIterable { + case active = "active" + case inactive = "inactive" + case unknown = "unknown" + } + /// The token status as of the latest validity check. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/validity`. + public var validity: Components.Schemas.OrganizationSecretScanningAlert.ValidityPayload? + /// Whether the secret was publicly leaked. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/publicly_leaked`. + public var publiclyLeaked: Swift.Bool? + /// Whether the detected secret was found in multiple repositories in the same organization or enterprise. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/multi_repo`. + public var multiRepo: Swift.Bool? /// A boolean value representing whether or not alert is base64 encoded /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/is_base64_encoded`. + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/is_base64_encoded`. public var isBase64Encoded: Swift.Bool? - /// Creates a new `SecretScanningAlert`. + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/first_location_detected`. + public var firstLocationDetected: Components.Schemas.NullableSecretScanningFirstDetectedLocation? + /// A boolean value representing whether or not the token in the alert was detected in more than one location. + /// + /// - Remark: Generated from `#/components/schemas/organization-secret-scanning-alert/has_more_locations`. + public var hasMoreLocations: Swift.Bool? + /// Creates a new `OrganizationSecretScanningAlert`. /// /// - Parameters: /// - number: @@ -1350,10 +1675,10 @@ public enum Components { /// - resolution: /// - resolvedAt: The time that the alert was resolved in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. /// - resolvedBy: - /// - resolutionComment: An optional comment to resolve an alert. /// - secretType: The type of secret that secret scanning detected. /// - secretTypeDisplayName: User-friendly name for the detected secret, matching the `secret_type`. /// - secret: The secret that was detected. + /// - repository: /// - pushProtectionBypassed: Whether push protection was bypassed for the detected secret. /// - pushProtectionBypassedBy: /// - pushProtectionBypassedAt: The time that push protection was bypassed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. @@ -1361,10 +1686,13 @@ public enum Components { /// - pushProtectionBypassRequestReviewerComment: An optional comment when reviewing a push protection bypass. /// - pushProtectionBypassRequestComment: An optional comment when requesting a push protection bypass. /// - pushProtectionBypassRequestHtmlUrl: The URL to a push protection bypass request. + /// - resolutionComment: The comment that was optionally added when this alert was closed /// - validity: The token status as of the latest validity check. - /// - publiclyLeaked: Whether the detected secret was publicly leaked. - /// - multiRepo: Whether the detected secret was found in multiple repositories under the same organization or enterprise. + /// - publiclyLeaked: Whether the secret was publicly leaked. + /// - multiRepo: Whether the detected secret was found in multiple repositories in the same organization or enterprise. /// - isBase64Encoded: A boolean value representing whether or not alert is base64 encoded + /// - firstLocationDetected: + /// - hasMoreLocations: A boolean value representing whether or not the token in the alert was detected in more than one location. public init( number: Components.Schemas.AlertNumber? = nil, createdAt: Components.Schemas.AlertCreatedAt? = nil, @@ -1376,10 +1704,10 @@ public enum Components { resolution: Components.Schemas.SecretScanningAlertResolution? = nil, resolvedAt: Foundation.Date? = nil, resolvedBy: Components.Schemas.NullableSimpleUser? = nil, - resolutionComment: Swift.String? = nil, secretType: Swift.String? = nil, secretTypeDisplayName: Swift.String? = nil, secret: Swift.String? = nil, + repository: Components.Schemas.SimpleRepository? = nil, pushProtectionBypassed: Swift.Bool? = nil, pushProtectionBypassedBy: Components.Schemas.NullableSimpleUser? = nil, pushProtectionBypassedAt: Foundation.Date? = nil, @@ -1387,10 +1715,13 @@ public enum Components { pushProtectionBypassRequestReviewerComment: Swift.String? = nil, pushProtectionBypassRequestComment: Swift.String? = nil, pushProtectionBypassRequestHtmlUrl: Swift.String? = nil, - validity: Components.Schemas.SecretScanningAlert.ValidityPayload? = nil, + resolutionComment: Swift.String? = nil, + validity: Components.Schemas.OrganizationSecretScanningAlert.ValidityPayload? = nil, publiclyLeaked: Swift.Bool? = nil, multiRepo: Swift.Bool? = nil, - isBase64Encoded: Swift.Bool? = nil + isBase64Encoded: Swift.Bool? = nil, + firstLocationDetected: Components.Schemas.NullableSecretScanningFirstDetectedLocation? = nil, + hasMoreLocations: Swift.Bool? = nil ) { self.number = number self.createdAt = createdAt @@ -1402,10 +1733,10 @@ public enum Components { self.resolution = resolution self.resolvedAt = resolvedAt self.resolvedBy = resolvedBy - self.resolutionComment = resolutionComment self.secretType = secretType self.secretTypeDisplayName = secretTypeDisplayName self.secret = secret + self.repository = repository self.pushProtectionBypassed = pushProtectionBypassed self.pushProtectionBypassedBy = pushProtectionBypassedBy self.pushProtectionBypassedAt = pushProtectionBypassedAt @@ -1413,10 +1744,13 @@ public enum Components { self.pushProtectionBypassRequestReviewerComment = pushProtectionBypassRequestReviewerComment self.pushProtectionBypassRequestComment = pushProtectionBypassRequestComment self.pushProtectionBypassRequestHtmlUrl = pushProtectionBypassRequestHtmlUrl + self.resolutionComment = resolutionComment self.validity = validity self.publiclyLeaked = publiclyLeaked self.multiRepo = multiRepo self.isBase64Encoded = isBase64Encoded + self.firstLocationDetected = firstLocationDetected + self.hasMoreLocations = hasMoreLocations } public enum CodingKeys: String, CodingKey { case number @@ -1429,10 +1763,10 @@ public enum Components { case resolution case resolvedAt = "resolved_at" case resolvedBy = "resolved_by" - case resolutionComment = "resolution_comment" case secretType = "secret_type" case secretTypeDisplayName = "secret_type_display_name" case secret + case repository case pushProtectionBypassed = "push_protection_bypassed" case pushProtectionBypassedBy = "push_protection_bypassed_by" case pushProtectionBypassedAt = "push_protection_bypassed_at" @@ -1440,395 +1774,237 @@ public enum Components { case pushProtectionBypassRequestReviewerComment = "push_protection_bypass_request_reviewer_comment" case pushProtectionBypassRequestComment = "push_protection_bypass_request_comment" case pushProtectionBypassRequestHtmlUrl = "push_protection_bypass_request_html_url" + case resolutionComment = "resolution_comment" case validity case publiclyLeaked = "publicly_leaked" case multiRepo = "multi_repo" case isBase64Encoded = "is_base64_encoded" + case firstLocationDetected = "first_location_detected" + case hasMoreLocations = "has_more_locations" } } - /// An optional comment when closing or reopening an alert. Cannot be updated or deleted. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-alert-resolution-comment`. - public typealias SecretScanningAlertResolutionComment = Swift.String - /// Represents a 'commit' secret scanning location type. This location type shows that a secret was detected inside a commit to a repository. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit`. - public struct SecretScanningLocationCommit: Codable, Hashable, Sendable { - /// The file path in the repository - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/path`. - public var path: Swift.String - /// Line number at which the secret starts in the file - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/start_line`. - public var startLine: Swift.Double - /// Line number at which the secret ends in the file - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/end_line`. - public var endLine: Swift.Double - /// The column at which the secret starts within the start line when the file is interpreted as 8BIT ASCII - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/start_column`. - public var startColumn: Swift.Double - /// The column at which the secret ends within the end line when the file is interpreted as 8BIT ASCII - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/end_column`. - public var endColumn: Swift.Double - /// SHA-1 hash ID of the associated blob - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/blob_sha`. - public var blobSha: Swift.String - /// The API URL to get the associated blob resource - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/blob_url`. - public var blobUrl: Swift.String - /// SHA-1 hash ID of the associated commit - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/commit_sha`. - public var commitSha: Swift.String - /// The API URL to get the associated commit resource - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-commit/commit_url`. - public var commitUrl: Swift.String - /// Creates a new `SecretScanningLocationCommit`. - /// - /// - Parameters: - /// - path: The file path in the repository - /// - startLine: Line number at which the secret starts in the file - /// - endLine: Line number at which the secret ends in the file - /// - startColumn: The column at which the secret starts within the start line when the file is interpreted as 8BIT ASCII - /// - endColumn: The column at which the secret ends within the end line when the file is interpreted as 8BIT ASCII - /// - blobSha: SHA-1 hash ID of the associated blob - /// - blobUrl: The API URL to get the associated blob resource - /// - commitSha: SHA-1 hash ID of the associated commit - /// - commitUrl: The API URL to get the associated commit resource - public init( - path: Swift.String, - startLine: Swift.Double, - endLine: Swift.Double, - startColumn: Swift.Double, - endColumn: Swift.Double, - blobSha: Swift.String, - blobUrl: Swift.String, - commitSha: Swift.String, - commitUrl: Swift.String - ) { - self.path = path - self.startLine = startLine - self.endLine = endLine - self.startColumn = startColumn - self.endColumn = endColumn - self.blobSha = blobSha - self.blobUrl = blobUrl - self.commitSha = commitSha - self.commitUrl = commitUrl - } - public enum CodingKeys: String, CodingKey { - case path - case startLine = "start_line" - case endLine = "end_line" - case startColumn = "start_column" - case endColumn = "end_column" - case blobSha = "blob_sha" - case blobUrl = "blob_url" - case commitSha = "commit_sha" - case commitUrl = "commit_url" - } - } - /// Represents a 'wiki_commit' secret scanning location type. This location type shows that a secret was detected inside a commit to a repository wiki. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit`. - public struct SecretScanningLocationWikiCommit: Codable, Hashable, Sendable { - /// The file path of the wiki page - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/path`. - public var path: Swift.String - /// Line number at which the secret starts in the file - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/start_line`. - public var startLine: Swift.Double - /// Line number at which the secret ends in the file - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/end_line`. - public var endLine: Swift.Double - /// The column at which the secret starts within the start line when the file is interpreted as 8-bit ASCII. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/start_column`. - public var startColumn: Swift.Double - /// The column at which the secret ends within the end line when the file is interpreted as 8-bit ASCII. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/end_column`. - public var endColumn: Swift.Double - /// SHA-1 hash ID of the associated blob - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/blob_sha`. - public var blobSha: Swift.String - /// The GitHub URL to get the associated wiki page - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/page_url`. - public var pageUrl: Swift.String - /// SHA-1 hash ID of the associated commit - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/commit_sha`. - public var commitSha: Swift.String - /// The GitHub URL to get the associated wiki commit - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-wiki-commit/commit_url`. - public var commitUrl: Swift.String - /// Creates a new `SecretScanningLocationWikiCommit`. - /// - /// - Parameters: - /// - path: The file path of the wiki page - /// - startLine: Line number at which the secret starts in the file - /// - endLine: Line number at which the secret ends in the file - /// - startColumn: The column at which the secret starts within the start line when the file is interpreted as 8-bit ASCII. - /// - endColumn: The column at which the secret ends within the end line when the file is interpreted as 8-bit ASCII. - /// - blobSha: SHA-1 hash ID of the associated blob - /// - pageUrl: The GitHub URL to get the associated wiki page - /// - commitSha: SHA-1 hash ID of the associated commit - /// - commitUrl: The GitHub URL to get the associated wiki commit - public init( - path: Swift.String, - startLine: Swift.Double, - endLine: Swift.Double, - startColumn: Swift.Double, - endColumn: Swift.Double, - blobSha: Swift.String, - pageUrl: Swift.String, - commitSha: Swift.String, - commitUrl: Swift.String - ) { - self.path = path - self.startLine = startLine - self.endLine = endLine - self.startColumn = startColumn - self.endColumn = endColumn - self.blobSha = blobSha - self.pageUrl = pageUrl - self.commitSha = commitSha - self.commitUrl = commitUrl - } - public enum CodingKeys: String, CodingKey { - case path - case startLine = "start_line" - case endLine = "end_line" - case startColumn = "start_column" - case endColumn = "end_column" - case blobSha = "blob_sha" - case pageUrl = "page_url" - case commitSha = "commit_sha" - case commitUrl = "commit_url" - } - } - /// Represents an 'issue_title' secret scanning location type. This location type shows that a secret was detected in the title of an issue. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-title`. - public struct SecretScanningLocationIssueTitle: Codable, Hashable, Sendable { - /// The API URL to get the issue where the secret was detected. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-title/issue_title_url`. - public var issueTitleUrl: Swift.String - /// Creates a new `SecretScanningLocationIssueTitle`. - /// - /// - Parameters: - /// - issueTitleUrl: The API URL to get the issue where the secret was detected. - public init(issueTitleUrl: Swift.String) { - self.issueTitleUrl = issueTitleUrl - } - public enum CodingKeys: String, CodingKey { - case issueTitleUrl = "issue_title_url" - } - } - /// Represents an 'issue_body' secret scanning location type. This location type shows that a secret was detected in the body of an issue. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-body`. - public struct SecretScanningLocationIssueBody: Codable, Hashable, Sendable { - /// The API URL to get the issue where the secret was detected. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-body/issue_body_url`. - public var issueBodyUrl: Swift.String - /// Creates a new `SecretScanningLocationIssueBody`. - /// - /// - Parameters: - /// - issueBodyUrl: The API URL to get the issue where the secret was detected. - public init(issueBodyUrl: Swift.String) { - self.issueBodyUrl = issueBodyUrl - } - public enum CodingKeys: String, CodingKey { - case issueBodyUrl = "issue_body_url" - } - } - /// Represents an 'issue_comment' secret scanning location type. This location type shows that a secret was detected in a comment on an issue. + /// The ID of the push protection bypass placeholder. This value is returned on any push protected routes. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-comment`. - public struct SecretScanningLocationIssueComment: Codable, Hashable, Sendable { - /// The API URL to get the issue comment where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-push-protection-bypass-placeholder-id`. + public typealias SecretScanningPushProtectionBypassPlaceholderId = Swift.String + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert`. + public struct SecretScanningAlert: Codable, Hashable, Sendable { + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/number`. + public var number: Components.Schemas.AlertNumber? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/created_at`. + public var createdAt: Components.Schemas.AlertCreatedAt? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/updated_at`. + public var updatedAt: Components.Schemas.NullableAlertUpdatedAt? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/url`. + public var url: Components.Schemas.AlertUrl? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/html_url`. + public var htmlUrl: Components.Schemas.AlertHtmlUrl? + /// The REST API URL of the code locations for this alert. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-issue-comment/issue_comment_url`. - public var issueCommentUrl: Swift.String - /// Creates a new `SecretScanningLocationIssueComment`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/locations_url`. + public var locationsUrl: Swift.String? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/state`. + public var state: Components.Schemas.SecretScanningAlertState? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolution`. + public var resolution: Components.Schemas.SecretScanningAlertResolution? + /// The time that the alert was resolved in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. /// - /// - Parameters: - /// - issueCommentUrl: The API URL to get the issue comment where the secret was detected. - public init(issueCommentUrl: Swift.String) { - self.issueCommentUrl = issueCommentUrl - } - public enum CodingKeys: String, CodingKey { - case issueCommentUrl = "issue_comment_url" - } - } - /// Represents a 'discussion_title' secret scanning location type. This location type shows that a secret was detected in the title of a discussion. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-title`. - public struct SecretScanningLocationDiscussionTitle: Codable, Hashable, Sendable { - /// The URL to the discussion where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolved_at`. + public var resolvedAt: Foundation.Date? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolved_by`. + public var resolvedBy: Components.Schemas.NullableSimpleUser? + /// An optional comment to resolve an alert. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-title/discussion_title_url`. - public var discussionTitleUrl: Swift.String - /// Creates a new `SecretScanningLocationDiscussionTitle`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/resolution_comment`. + public var resolutionComment: Swift.String? + /// The type of secret that secret scanning detected. /// - /// - Parameters: - /// - discussionTitleUrl: The URL to the discussion where the secret was detected. - public init(discussionTitleUrl: Swift.String) { - self.discussionTitleUrl = discussionTitleUrl - } - public enum CodingKeys: String, CodingKey { - case discussionTitleUrl = "discussion_title_url" - } - } - /// Represents a 'discussion_body' secret scanning location type. This location type shows that a secret was detected in the body of a discussion. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-body`. - public struct SecretScanningLocationDiscussionBody: Codable, Hashable, Sendable { - /// The URL to the discussion where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/secret_type`. + public var secretType: Swift.String? + /// User-friendly name for the detected secret, matching the `secret_type`. + /// For a list of built-in patterns, see "[Supported secret scanning patterns](https://docs.github.com/code-security/secret-scanning/introduction/supported-secret-scanning-patterns#supported-secrets)." /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-body/discussion_body_url`. - public var discussionBodyUrl: Swift.String - /// Creates a new `SecretScanningLocationDiscussionBody`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/secret_type_display_name`. + public var secretTypeDisplayName: Swift.String? + /// The secret that was detected. /// - /// - Parameters: - /// - discussionBodyUrl: The URL to the discussion where the secret was detected. - public init(discussionBodyUrl: Swift.String) { - self.discussionBodyUrl = discussionBodyUrl - } - public enum CodingKeys: String, CodingKey { - case discussionBodyUrl = "discussion_body_url" - } - } - /// Represents a 'discussion_comment' secret scanning location type. This location type shows that a secret was detected in a comment on a discussion. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-comment`. - public struct SecretScanningLocationDiscussionComment: Codable, Hashable, Sendable { - /// The API URL to get the discussion comment where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/secret`. + public var secret: Swift.String? + /// Whether push protection was bypassed for the detected secret. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-discussion-comment/discussion_comment_url`. - public var discussionCommentUrl: Swift.String - /// Creates a new `SecretScanningLocationDiscussionComment`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypassed`. + public var pushProtectionBypassed: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypassed_by`. + public var pushProtectionBypassedBy: Components.Schemas.NullableSimpleUser? + /// The time that push protection was bypassed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. /// - /// - Parameters: - /// - discussionCommentUrl: The API URL to get the discussion comment where the secret was detected. - public init(discussionCommentUrl: Swift.String) { - self.discussionCommentUrl = discussionCommentUrl - } - public enum CodingKeys: String, CodingKey { - case discussionCommentUrl = "discussion_comment_url" - } - } - /// Represents a 'pull_request_title' secret scanning location type. This location type shows that a secret was detected in the title of a pull request. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-title`. - public struct SecretScanningLocationPullRequestTitle: Codable, Hashable, Sendable { - /// The API URL to get the pull request where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypassed_at`. + public var pushProtectionBypassedAt: Foundation.Date? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_reviewer`. + public var pushProtectionBypassRequestReviewer: Components.Schemas.NullableSimpleUser? + /// An optional comment when reviewing a push protection bypass. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-title/pull_request_title_url`. - public var pullRequestTitleUrl: Swift.String - /// Creates a new `SecretScanningLocationPullRequestTitle`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_reviewer_comment`. + public var pushProtectionBypassRequestReviewerComment: Swift.String? + /// An optional comment when requesting a push protection bypass. /// - /// - Parameters: - /// - pullRequestTitleUrl: The API URL to get the pull request where the secret was detected. - public init(pullRequestTitleUrl: Swift.String) { - self.pullRequestTitleUrl = pullRequestTitleUrl - } - public enum CodingKeys: String, CodingKey { - case pullRequestTitleUrl = "pull_request_title_url" - } - } - /// Represents a 'pull_request_body' secret scanning location type. This location type shows that a secret was detected in the body of a pull request. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-body`. - public struct SecretScanningLocationPullRequestBody: Codable, Hashable, Sendable { - /// The API URL to get the pull request where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_comment`. + public var pushProtectionBypassRequestComment: Swift.String? + /// The URL to a push protection bypass request. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-body/pull_request_body_url`. - public var pullRequestBodyUrl: Swift.String - /// Creates a new `SecretScanningLocationPullRequestBody`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/push_protection_bypass_request_html_url`. + public var pushProtectionBypassRequestHtmlUrl: Swift.String? + /// The token status as of the latest validity check. /// - /// - Parameters: - /// - pullRequestBodyUrl: The API URL to get the pull request where the secret was detected. - public init(pullRequestBodyUrl: Swift.String) { - self.pullRequestBodyUrl = pullRequestBodyUrl - } - public enum CodingKeys: String, CodingKey { - case pullRequestBodyUrl = "pull_request_body_url" + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/validity`. + @frozen public enum ValidityPayload: String, Codable, Hashable, Sendable, CaseIterable { + case active = "active" + case inactive = "inactive" + case unknown = "unknown" } - } - /// Represents a 'pull_request_comment' secret scanning location type. This location type shows that a secret was detected in a comment on a pull request. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-comment`. - public struct SecretScanningLocationPullRequestComment: Codable, Hashable, Sendable { - /// The API URL to get the pull request comment where the secret was detected. + /// The token status as of the latest validity check. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-comment/pull_request_comment_url`. - public var pullRequestCommentUrl: Swift.String - /// Creates a new `SecretScanningLocationPullRequestComment`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/validity`. + public var validity: Components.Schemas.SecretScanningAlert.ValidityPayload? + /// Whether the detected secret was publicly leaked. /// - /// - Parameters: - /// - pullRequestCommentUrl: The API URL to get the pull request comment where the secret was detected. - public init(pullRequestCommentUrl: Swift.String) { - self.pullRequestCommentUrl = pullRequestCommentUrl - } - public enum CodingKeys: String, CodingKey { - case pullRequestCommentUrl = "pull_request_comment_url" - } - } - /// Represents a 'pull_request_review' secret scanning location type. This location type shows that a secret was detected in a review on a pull request. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review`. - public struct SecretScanningLocationPullRequestReview: Codable, Hashable, Sendable { - /// The API URL to get the pull request review where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/publicly_leaked`. + public var publiclyLeaked: Swift.Bool? + /// Whether the detected secret was found in multiple repositories under the same organization or enterprise. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review/pull_request_review_url`. - public var pullRequestReviewUrl: Swift.String - /// Creates a new `SecretScanningLocationPullRequestReview`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/multi_repo`. + public var multiRepo: Swift.Bool? + /// A boolean value representing whether or not alert is base64 encoded /// - /// - Parameters: - /// - pullRequestReviewUrl: The API URL to get the pull request review where the secret was detected. - public init(pullRequestReviewUrl: Swift.String) { - self.pullRequestReviewUrl = pullRequestReviewUrl - } - public enum CodingKeys: String, CodingKey { - case pullRequestReviewUrl = "pull_request_review_url" - } - } - /// Represents a 'pull_request_review_comment' secret scanning location type. This location type shows that a secret was detected in a review comment on a pull request. - /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review-comment`. - public struct SecretScanningLocationPullRequestReviewComment: Codable, Hashable, Sendable { - /// The API URL to get the pull request review comment where the secret was detected. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/is_base64_encoded`. + public var isBase64Encoded: Swift.Bool? + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/first_location_detected`. + public var firstLocationDetected: Components.Schemas.NullableSecretScanningFirstDetectedLocation? + /// A boolean value representing whether or not the token in the alert was detected in more than one location. /// - /// - Remark: Generated from `#/components/schemas/secret-scanning-location-pull-request-review-comment/pull_request_review_comment_url`. - public var pullRequestReviewCommentUrl: Swift.String - /// Creates a new `SecretScanningLocationPullRequestReviewComment`. + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert/has_more_locations`. + public var hasMoreLocations: Swift.Bool? + /// Creates a new `SecretScanningAlert`. /// /// - Parameters: - /// - pullRequestReviewCommentUrl: The API URL to get the pull request review comment where the secret was detected. - public init(pullRequestReviewCommentUrl: Swift.String) { - self.pullRequestReviewCommentUrl = pullRequestReviewCommentUrl + /// - number: + /// - createdAt: + /// - updatedAt: + /// - url: + /// - htmlUrl: + /// - locationsUrl: The REST API URL of the code locations for this alert. + /// - state: + /// - resolution: + /// - resolvedAt: The time that the alert was resolved in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// - resolvedBy: + /// - resolutionComment: An optional comment to resolve an alert. + /// - secretType: The type of secret that secret scanning detected. + /// - secretTypeDisplayName: User-friendly name for the detected secret, matching the `secret_type`. + /// - secret: The secret that was detected. + /// - pushProtectionBypassed: Whether push protection was bypassed for the detected secret. + /// - pushProtectionBypassedBy: + /// - pushProtectionBypassedAt: The time that push protection was bypassed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. + /// - pushProtectionBypassRequestReviewer: + /// - pushProtectionBypassRequestReviewerComment: An optional comment when reviewing a push protection bypass. + /// - pushProtectionBypassRequestComment: An optional comment when requesting a push protection bypass. + /// - pushProtectionBypassRequestHtmlUrl: The URL to a push protection bypass request. + /// - validity: The token status as of the latest validity check. + /// - publiclyLeaked: Whether the detected secret was publicly leaked. + /// - multiRepo: Whether the detected secret was found in multiple repositories under the same organization or enterprise. + /// - isBase64Encoded: A boolean value representing whether or not alert is base64 encoded + /// - firstLocationDetected: + /// - hasMoreLocations: A boolean value representing whether or not the token in the alert was detected in more than one location. + public init( + number: Components.Schemas.AlertNumber? = nil, + createdAt: Components.Schemas.AlertCreatedAt? = nil, + updatedAt: Components.Schemas.NullableAlertUpdatedAt? = nil, + url: Components.Schemas.AlertUrl? = nil, + htmlUrl: Components.Schemas.AlertHtmlUrl? = nil, + locationsUrl: Swift.String? = nil, + state: Components.Schemas.SecretScanningAlertState? = nil, + resolution: Components.Schemas.SecretScanningAlertResolution? = nil, + resolvedAt: Foundation.Date? = nil, + resolvedBy: Components.Schemas.NullableSimpleUser? = nil, + resolutionComment: Swift.String? = nil, + secretType: Swift.String? = nil, + secretTypeDisplayName: Swift.String? = nil, + secret: Swift.String? = nil, + pushProtectionBypassed: Swift.Bool? = nil, + pushProtectionBypassedBy: Components.Schemas.NullableSimpleUser? = nil, + pushProtectionBypassedAt: Foundation.Date? = nil, + pushProtectionBypassRequestReviewer: Components.Schemas.NullableSimpleUser? = nil, + pushProtectionBypassRequestReviewerComment: Swift.String? = nil, + pushProtectionBypassRequestComment: Swift.String? = nil, + pushProtectionBypassRequestHtmlUrl: Swift.String? = nil, + validity: Components.Schemas.SecretScanningAlert.ValidityPayload? = nil, + publiclyLeaked: Swift.Bool? = nil, + multiRepo: Swift.Bool? = nil, + isBase64Encoded: Swift.Bool? = nil, + firstLocationDetected: Components.Schemas.NullableSecretScanningFirstDetectedLocation? = nil, + hasMoreLocations: Swift.Bool? = nil + ) { + self.number = number + self.createdAt = createdAt + self.updatedAt = updatedAt + self.url = url + self.htmlUrl = htmlUrl + self.locationsUrl = locationsUrl + self.state = state + self.resolution = resolution + self.resolvedAt = resolvedAt + self.resolvedBy = resolvedBy + self.resolutionComment = resolutionComment + self.secretType = secretType + self.secretTypeDisplayName = secretTypeDisplayName + self.secret = secret + self.pushProtectionBypassed = pushProtectionBypassed + self.pushProtectionBypassedBy = pushProtectionBypassedBy + self.pushProtectionBypassedAt = pushProtectionBypassedAt + self.pushProtectionBypassRequestReviewer = pushProtectionBypassRequestReviewer + self.pushProtectionBypassRequestReviewerComment = pushProtectionBypassRequestReviewerComment + self.pushProtectionBypassRequestComment = pushProtectionBypassRequestComment + self.pushProtectionBypassRequestHtmlUrl = pushProtectionBypassRequestHtmlUrl + self.validity = validity + self.publiclyLeaked = publiclyLeaked + self.multiRepo = multiRepo + self.isBase64Encoded = isBase64Encoded + self.firstLocationDetected = firstLocationDetected + self.hasMoreLocations = hasMoreLocations } public enum CodingKeys: String, CodingKey { - case pullRequestReviewCommentUrl = "pull_request_review_comment_url" + case number + case createdAt = "created_at" + case updatedAt = "updated_at" + case url + case htmlUrl = "html_url" + case locationsUrl = "locations_url" + case state + case resolution + case resolvedAt = "resolved_at" + case resolvedBy = "resolved_by" + case resolutionComment = "resolution_comment" + case secretType = "secret_type" + case secretTypeDisplayName = "secret_type_display_name" + case secret + case pushProtectionBypassed = "push_protection_bypassed" + case pushProtectionBypassedBy = "push_protection_bypassed_by" + case pushProtectionBypassedAt = "push_protection_bypassed_at" + case pushProtectionBypassRequestReviewer = "push_protection_bypass_request_reviewer" + case pushProtectionBypassRequestReviewerComment = "push_protection_bypass_request_reviewer_comment" + case pushProtectionBypassRequestComment = "push_protection_bypass_request_comment" + case pushProtectionBypassRequestHtmlUrl = "push_protection_bypass_request_html_url" + case validity + case publiclyLeaked = "publicly_leaked" + case multiRepo = "multi_repo" + case isBase64Encoded = "is_base64_encoded" + case firstLocationDetected = "first_location_detected" + case hasMoreLocations = "has_more_locations" } } + /// An optional comment when closing or reopening an alert. Cannot be updated or deleted. + /// + /// - Remark: Generated from `#/components/schemas/secret-scanning-alert-resolution-comment`. + public typealias SecretScanningAlertResolutionComment = Swift.String /// - Remark: Generated from `#/components/schemas/secret-scanning-location`. public struct SecretScanningLocation: Codable, Hashable, Sendable { /// The location type. Because secrets may be found in different types of resources (ie. code, comments, issues, pull requests, discussions), this field identifies the type of resource where the secret was found. From 0f432757c8b8e47491e2064d963bd880c75435a7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:31:49 +0000 Subject: [PATCH 14/17] Commit via running: make Sources/teams --- Sources/teams/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/teams/Types.swift b/Sources/teams/Types.swift index 1ae0e1b934..309709ae1e 100644 --- a/Sources/teams/Types.swift +++ b/Sources/teams/Types.swift @@ -3072,6 +3072,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -3162,6 +3186,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -3249,7 +3274,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -3338,6 +3364,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -3427,6 +3454,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// Groups of organization members that gives permissions on specified repositories. From 3e5ed8149b7a4bf7efdf310eb8856981ca23530b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:32:13 +0000 Subject: [PATCH 15/17] Commit via running: make Sources/users --- Sources/users/Client.swift | 235 +++++++++++++ Sources/users/Types.swift | 676 +++++++++++++++++++++++++++++++++++++ 2 files changed, 911 insertions(+) diff --git a/Sources/users/Client.swift b/Sources/users/Client.swift index 454dd60f53..4b7df52b88 100644 --- a/Sources/users/Client.swift +++ b/Sources/users/Client.swift @@ -4656,6 +4656,241 @@ public struct Client: APIProtocol { } ) } + /// Delete attestations in bulk + /// + /// Delete artifact attestations in bulk by either subject digests or unique ID. + /// + /// - Remark: HTTP `POST /users/{username}/attestations/delete-request`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/delete-request/post(users/delete-attestations-bulk)`. + public func usersDeleteAttestationsBulk(_ input: Operations.UsersDeleteAttestationsBulk.Input) async throws -> Operations.UsersDeleteAttestationsBulk.Output { + try await client.send( + input: input, + forOperation: Operations.UsersDeleteAttestationsBulk.id, + serializer: { input in + let path = try converter.renderedPath( + template: "/users/{}/attestations/delete-request", + parameters: [ + input.path.username + ] + ) + var request: HTTPTypes.HTTPRequest = .init( + soar_path: path, + method: .post + ) + suppressMutabilityWarning(&request) + converter.setAcceptHeader( + in: &request.headerFields, + contentTypes: input.headers.accept + ) + let body: OpenAPIRuntime.HTTPBody? + switch input.body { + case let .json(value): + body = try converter.setRequiredRequestBodyAsJSON( + value, + headerFields: &request.headerFields, + contentType: "application/json; charset=utf-8" + ) + } + return (request, body) + }, + deserializer: { response, responseBody in + switch response.status.code { + case 200: + return .ok(.init()) + case 404: + let contentType = converter.extractContentTypeIfPresent(in: response.headerFields) + let body: Components.Responses.NotFound.Body + let chosenContentType = try converter.bestContentType( + received: contentType, + options: [ + "application/json" + ] + ) + switch chosenContentType { + case "application/json": + body = try await converter.getResponseBodyAsJSON( + Components.Schemas.BasicError.self, + from: responseBody, + transforming: { value in + .json(value) + } + ) + default: + preconditionFailure("bestContentType chose an invalid content type.") + } + return .notFound(.init(body: body)) + default: + return .undocumented( + statusCode: response.status.code, + .init( + headerFields: response.headerFields, + body: responseBody + ) + ) + } + } + ) + } + /// Delete attestations by subject digest + /// + /// Delete an artifact attestation by subject digest. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/digest/{subject_digest}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)`. + public func usersDeleteAttestationsBySubjectDigest(_ input: Operations.UsersDeleteAttestationsBySubjectDigest.Input) async throws -> Operations.UsersDeleteAttestationsBySubjectDigest.Output { + try await client.send( + input: input, + forOperation: Operations.UsersDeleteAttestationsBySubjectDigest.id, + serializer: { input in + let path = try converter.renderedPath( + template: "/users/{}/attestations/digest/{}", + parameters: [ + input.path.username, + input.path.subjectDigest + ] + ) + var request: HTTPTypes.HTTPRequest = .init( + soar_path: path, + method: .delete + ) + suppressMutabilityWarning(&request) + converter.setAcceptHeader( + in: &request.headerFields, + contentTypes: input.headers.accept + ) + return (request, nil) + }, + deserializer: { response, responseBody in + switch response.status.code { + case 200: + return .ok(.init()) + case 204: + return .noContent(.init()) + case 404: + let contentType = converter.extractContentTypeIfPresent(in: response.headerFields) + let body: Components.Responses.NotFound.Body + let chosenContentType = try converter.bestContentType( + received: contentType, + options: [ + "application/json" + ] + ) + switch chosenContentType { + case "application/json": + body = try await converter.getResponseBodyAsJSON( + Components.Schemas.BasicError.self, + from: responseBody, + transforming: { value in + .json(value) + } + ) + default: + preconditionFailure("bestContentType chose an invalid content type.") + } + return .notFound(.init(body: body)) + default: + return .undocumented( + statusCode: response.status.code, + .init( + headerFields: response.headerFields, + body: responseBody + ) + ) + } + } + ) + } + /// Delete attestations by ID + /// + /// Delete an artifact attestation by unique ID that is associated with a repository owned by a user. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/{attestation_id}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)`. + public func usersDeleteAttestationsById(_ input: Operations.UsersDeleteAttestationsById.Input) async throws -> Operations.UsersDeleteAttestationsById.Output { + try await client.send( + input: input, + forOperation: Operations.UsersDeleteAttestationsById.id, + serializer: { input in + let path = try converter.renderedPath( + template: "/users/{}/attestations/{}", + parameters: [ + input.path.username, + input.path.attestationId + ] + ) + var request: HTTPTypes.HTTPRequest = .init( + soar_path: path, + method: .delete + ) + suppressMutabilityWarning(&request) + converter.setAcceptHeader( + in: &request.headerFields, + contentTypes: input.headers.accept + ) + return (request, nil) + }, + deserializer: { response, responseBody in + switch response.status.code { + case 200: + return .ok(.init()) + case 204: + return .noContent(.init()) + case 403: + let contentType = converter.extractContentTypeIfPresent(in: response.headerFields) + let body: Components.Responses.Forbidden.Body + let chosenContentType = try converter.bestContentType( + received: contentType, + options: [ + "application/json" + ] + ) + switch chosenContentType { + case "application/json": + body = try await converter.getResponseBodyAsJSON( + Components.Schemas.BasicError.self, + from: responseBody, + transforming: { value in + .json(value) + } + ) + default: + preconditionFailure("bestContentType chose an invalid content type.") + } + return .forbidden(.init(body: body)) + case 404: + let contentType = converter.extractContentTypeIfPresent(in: response.headerFields) + let body: Components.Responses.NotFound.Body + let chosenContentType = try converter.bestContentType( + received: contentType, + options: [ + "application/json" + ] + ) + switch chosenContentType { + case "application/json": + body = try await converter.getResponseBodyAsJSON( + Components.Schemas.BasicError.self, + from: responseBody, + transforming: { value in + .json(value) + } + ) + default: + preconditionFailure("bestContentType chose an invalid content type.") + } + return .notFound(.init(body: body)) + default: + return .undocumented( + statusCode: response.status.code, + .init( + headerFields: response.headerFields, + body: responseBody + ) + ) + } + } + ) + } /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by a user. diff --git a/Sources/users/Types.swift b/Sources/users/Types.swift index 4a484b9249..382767aa34 100644 --- a/Sources/users/Types.swift +++ b/Sources/users/Types.swift @@ -300,6 +300,27 @@ public protocol APIProtocol: Sendable { /// - Remark: HTTP `GET /users/{username}`. /// - Remark: Generated from `#/paths//users/{username}/get(users/get-by-username)`. func usersGetByUsername(_ input: Operations.UsersGetByUsername.Input) async throws -> Operations.UsersGetByUsername.Output + /// Delete attestations in bulk + /// + /// Delete artifact attestations in bulk by either subject digests or unique ID. + /// + /// - Remark: HTTP `POST /users/{username}/attestations/delete-request`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/delete-request/post(users/delete-attestations-bulk)`. + func usersDeleteAttestationsBulk(_ input: Operations.UsersDeleteAttestationsBulk.Input) async throws -> Operations.UsersDeleteAttestationsBulk.Output + /// Delete attestations by subject digest + /// + /// Delete an artifact attestation by subject digest. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/digest/{subject_digest}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)`. + func usersDeleteAttestationsBySubjectDigest(_ input: Operations.UsersDeleteAttestationsBySubjectDigest.Input) async throws -> Operations.UsersDeleteAttestationsBySubjectDigest.Output + /// Delete attestations by ID + /// + /// Delete an artifact attestation by unique ID that is associated with a repository owned by a user. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/{attestation_id}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)`. + func usersDeleteAttestationsById(_ input: Operations.UsersDeleteAttestationsById.Input) async throws -> Operations.UsersDeleteAttestationsById.Output /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by a user. @@ -930,6 +951,53 @@ extension APIProtocol { headers: headers )) } + /// Delete attestations in bulk + /// + /// Delete artifact attestations in bulk by either subject digests or unique ID. + /// + /// - Remark: HTTP `POST /users/{username}/attestations/delete-request`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/delete-request/post(users/delete-attestations-bulk)`. + public func usersDeleteAttestationsBulk( + path: Operations.UsersDeleteAttestationsBulk.Input.Path, + headers: Operations.UsersDeleteAttestationsBulk.Input.Headers = .init(), + body: Operations.UsersDeleteAttestationsBulk.Input.Body + ) async throws -> Operations.UsersDeleteAttestationsBulk.Output { + try await usersDeleteAttestationsBulk(Operations.UsersDeleteAttestationsBulk.Input( + path: path, + headers: headers, + body: body + )) + } + /// Delete attestations by subject digest + /// + /// Delete an artifact attestation by subject digest. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/digest/{subject_digest}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)`. + public func usersDeleteAttestationsBySubjectDigest( + path: Operations.UsersDeleteAttestationsBySubjectDigest.Input.Path, + headers: Operations.UsersDeleteAttestationsBySubjectDigest.Input.Headers = .init() + ) async throws -> Operations.UsersDeleteAttestationsBySubjectDigest.Output { + try await usersDeleteAttestationsBySubjectDigest(Operations.UsersDeleteAttestationsBySubjectDigest.Input( + path: path, + headers: headers + )) + } + /// Delete attestations by ID + /// + /// Delete an artifact attestation by unique ID that is associated with a repository owned by a user. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/{attestation_id}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)`. + public func usersDeleteAttestationsById( + path: Operations.UsersDeleteAttestationsById.Input.Path, + headers: Operations.UsersDeleteAttestationsById.Input.Headers = .init() + ) async throws -> Operations.UsersDeleteAttestationsById.Output { + try await usersDeleteAttestationsById(Operations.UsersDeleteAttestationsById.Input( + path: path, + headers: headers + )) + } /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by a user. @@ -11285,6 +11353,614 @@ public enum Operations { } } } + /// Delete attestations in bulk + /// + /// Delete artifact attestations in bulk by either subject digests or unique ID. + /// + /// - Remark: HTTP `POST /users/{username}/attestations/delete-request`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/delete-request/post(users/delete-attestations-bulk)`. + public enum UsersDeleteAttestationsBulk { + public static let id: Swift.String = "users/delete-attestations-bulk" + public struct Input: Sendable, Hashable { + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/path`. + public struct Path: Sendable, Hashable { + /// The handle for the GitHub user account. + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/path/username`. + public var username: Components.Parameters.Username + /// Creates a new `Path`. + /// + /// - Parameters: + /// - username: The handle for the GitHub user account. + public init(username: Components.Parameters.Username) { + self.username = username + } + } + public var path: Operations.UsersDeleteAttestationsBulk.Input.Path + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/header`. + public struct Headers: Sendable, Hashable { + public var accept: [OpenAPIRuntime.AcceptHeaderContentType] + /// Creates a new `Headers`. + /// + /// - Parameters: + /// - accept: + public init(accept: [OpenAPIRuntime.AcceptHeaderContentType] = .defaultValues()) { + self.accept = accept + } + } + public var headers: Operations.UsersDeleteAttestationsBulk.Input.Headers + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody`. + @frozen public enum Body: Sendable, Hashable { + /// The request body must include either `subject_digests` or `attestation_ids`, but not both. + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/json`. + @frozen public enum JsonPayload: Codable, Hashable, Sendable { + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/json/case1`. + public struct Case1Payload: Codable, Hashable, Sendable { + /// List of subject digests associated with the artifact attestations to delete. + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/json/case1/subject_digests`. + public var subjectDigests: [Swift.String] + /// Creates a new `Case1Payload`. + /// + /// - Parameters: + /// - subjectDigests: List of subject digests associated with the artifact attestations to delete. + public init(subjectDigests: [Swift.String]) { + self.subjectDigests = subjectDigests + } + public enum CodingKeys: String, CodingKey { + case subjectDigests = "subject_digests" + } + } + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/json/case1`. + case case1(Operations.UsersDeleteAttestationsBulk.Input.Body.JsonPayload.Case1Payload) + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/json/case2`. + public struct Case2Payload: Codable, Hashable, Sendable { + /// List of unique IDs associated with the artifact attestations to delete. + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/json/case2/attestation_ids`. + public var attestationIds: [Swift.Int] + /// Creates a new `Case2Payload`. + /// + /// - Parameters: + /// - attestationIds: List of unique IDs associated with the artifact attestations to delete. + public init(attestationIds: [Swift.Int]) { + self.attestationIds = attestationIds + } + public enum CodingKeys: String, CodingKey { + case attestationIds = "attestation_ids" + } + } + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/json/case2`. + case case2(Operations.UsersDeleteAttestationsBulk.Input.Body.JsonPayload.Case2Payload) + public init(from decoder: any Decoder) throws { + var errors: [any Error] = [] + do { + self = .case1(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + do { + self = .case2(try .init(from: decoder)) + return + } catch { + errors.append(error) + } + throw Swift.DecodingError.failedToDecodeOneOfSchema( + type: Self.self, + codingPath: decoder.codingPath, + errors: errors + ) + } + public func encode(to encoder: any Encoder) throws { + switch self { + case let .case1(value): + try value.encode(to: encoder) + case let .case2(value): + try value.encode(to: encoder) + } + } + } + /// - Remark: Generated from `#/paths/users/{username}/attestations/delete-request/POST/requestBody/content/application\/json`. + case json(Operations.UsersDeleteAttestationsBulk.Input.Body.JsonPayload) + } + public var body: Operations.UsersDeleteAttestationsBulk.Input.Body + /// Creates a new `Input`. + /// + /// - Parameters: + /// - path: + /// - headers: + /// - body: + public init( + path: Operations.UsersDeleteAttestationsBulk.Input.Path, + headers: Operations.UsersDeleteAttestationsBulk.Input.Headers = .init(), + body: Operations.UsersDeleteAttestationsBulk.Input.Body + ) { + self.path = path + self.headers = headers + self.body = body + } + } + @frozen public enum Output: Sendable, Hashable { + public struct Ok: Sendable, Hashable { + /// Creates a new `Ok`. + public init() {} + } + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/delete-request/post(users/delete-attestations-bulk)/responses/200`. + /// + /// HTTP response code: `200 ok`. + case ok(Operations.UsersDeleteAttestationsBulk.Output.Ok) + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/delete-request/post(users/delete-attestations-bulk)/responses/200`. + /// + /// HTTP response code: `200 ok`. + public static var ok: Self { + .ok(.init()) + } + /// The associated value of the enum case if `self` is `.ok`. + /// + /// - Throws: An error if `self` is not `.ok`. + /// - SeeAlso: `.ok`. + public var ok: Operations.UsersDeleteAttestationsBulk.Output.Ok { + get throws { + switch self { + case let .ok(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "ok", + response: self + ) + } + } + } + /// Resource not found + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/delete-request/post(users/delete-attestations-bulk)/responses/404`. + /// + /// HTTP response code: `404 notFound`. + case notFound(Components.Responses.NotFound) + /// The associated value of the enum case if `self` is `.notFound`. + /// + /// - Throws: An error if `self` is not `.notFound`. + /// - SeeAlso: `.notFound`. + public var notFound: Components.Responses.NotFound { + get throws { + switch self { + case let .notFound(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "notFound", + response: self + ) + } + } + } + /// Undocumented response. + /// + /// A response with a code that is not documented in the OpenAPI document. + case undocumented(statusCode: Swift.Int, OpenAPIRuntime.UndocumentedPayload) + } + @frozen public enum AcceptableContentType: AcceptableProtocol { + case json + case other(Swift.String) + public init?(rawValue: Swift.String) { + switch rawValue.lowercased() { + case "application/json": + self = .json + default: + self = .other(rawValue) + } + } + public var rawValue: Swift.String { + switch self { + case let .other(string): + return string + case .json: + return "application/json" + } + } + public static var allCases: [Self] { + [ + .json + ] + } + } + } + /// Delete attestations by subject digest + /// + /// Delete an artifact attestation by subject digest. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/digest/{subject_digest}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)`. + public enum UsersDeleteAttestationsBySubjectDigest { + public static let id: Swift.String = "users/delete-attestations-by-subject-digest" + public struct Input: Sendable, Hashable { + /// - Remark: Generated from `#/paths/users/{username}/attestations/digest/{subject_digest}/DELETE/path`. + public struct Path: Sendable, Hashable { + /// The handle for the GitHub user account. + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/digest/{subject_digest}/DELETE/path/username`. + public var username: Components.Parameters.Username + /// Subject Digest + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/digest/{subject_digest}/DELETE/path/subject_digest`. + public var subjectDigest: Swift.String + /// Creates a new `Path`. + /// + /// - Parameters: + /// - username: The handle for the GitHub user account. + /// - subjectDigest: Subject Digest + public init( + username: Components.Parameters.Username, + subjectDigest: Swift.String + ) { + self.username = username + self.subjectDigest = subjectDigest + } + } + public var path: Operations.UsersDeleteAttestationsBySubjectDigest.Input.Path + /// - Remark: Generated from `#/paths/users/{username}/attestations/digest/{subject_digest}/DELETE/header`. + public struct Headers: Sendable, Hashable { + public var accept: [OpenAPIRuntime.AcceptHeaderContentType] + /// Creates a new `Headers`. + /// + /// - Parameters: + /// - accept: + public init(accept: [OpenAPIRuntime.AcceptHeaderContentType] = .defaultValues()) { + self.accept = accept + } + } + public var headers: Operations.UsersDeleteAttestationsBySubjectDigest.Input.Headers + /// Creates a new `Input`. + /// + /// - Parameters: + /// - path: + /// - headers: + public init( + path: Operations.UsersDeleteAttestationsBySubjectDigest.Input.Path, + headers: Operations.UsersDeleteAttestationsBySubjectDigest.Input.Headers = .init() + ) { + self.path = path + self.headers = headers + } + } + @frozen public enum Output: Sendable, Hashable { + public struct Ok: Sendable, Hashable { + /// Creates a new `Ok`. + public init() {} + } + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)/responses/200`. + /// + /// HTTP response code: `200 ok`. + case ok(Operations.UsersDeleteAttestationsBySubjectDigest.Output.Ok) + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)/responses/200`. + /// + /// HTTP response code: `200 ok`. + public static var ok: Self { + .ok(.init()) + } + /// The associated value of the enum case if `self` is `.ok`. + /// + /// - Throws: An error if `self` is not `.ok`. + /// - SeeAlso: `.ok`. + public var ok: Operations.UsersDeleteAttestationsBySubjectDigest.Output.Ok { + get throws { + switch self { + case let .ok(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "ok", + response: self + ) + } + } + } + public struct NoContent: Sendable, Hashable { + /// Creates a new `NoContent`. + public init() {} + } + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)/responses/204`. + /// + /// HTTP response code: `204 noContent`. + case noContent(Operations.UsersDeleteAttestationsBySubjectDigest.Output.NoContent) + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)/responses/204`. + /// + /// HTTP response code: `204 noContent`. + public static var noContent: Self { + .noContent(.init()) + } + /// The associated value of the enum case if `self` is `.noContent`. + /// + /// - Throws: An error if `self` is not `.noContent`. + /// - SeeAlso: `.noContent`. + public var noContent: Operations.UsersDeleteAttestationsBySubjectDigest.Output.NoContent { + get throws { + switch self { + case let .noContent(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "noContent", + response: self + ) + } + } + } + /// Resource not found + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/digest/{subject_digest}/delete(users/delete-attestations-by-subject-digest)/responses/404`. + /// + /// HTTP response code: `404 notFound`. + case notFound(Components.Responses.NotFound) + /// The associated value of the enum case if `self` is `.notFound`. + /// + /// - Throws: An error if `self` is not `.notFound`. + /// - SeeAlso: `.notFound`. + public var notFound: Components.Responses.NotFound { + get throws { + switch self { + case let .notFound(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "notFound", + response: self + ) + } + } + } + /// Undocumented response. + /// + /// A response with a code that is not documented in the OpenAPI document. + case undocumented(statusCode: Swift.Int, OpenAPIRuntime.UndocumentedPayload) + } + @frozen public enum AcceptableContentType: AcceptableProtocol { + case json + case other(Swift.String) + public init?(rawValue: Swift.String) { + switch rawValue.lowercased() { + case "application/json": + self = .json + default: + self = .other(rawValue) + } + } + public var rawValue: Swift.String { + switch self { + case let .other(string): + return string + case .json: + return "application/json" + } + } + public static var allCases: [Self] { + [ + .json + ] + } + } + } + /// Delete attestations by ID + /// + /// Delete an artifact attestation by unique ID that is associated with a repository owned by a user. + /// + /// - Remark: HTTP `DELETE /users/{username}/attestations/{attestation_id}`. + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)`. + public enum UsersDeleteAttestationsById { + public static let id: Swift.String = "users/delete-attestations-by-id" + public struct Input: Sendable, Hashable { + /// - Remark: Generated from `#/paths/users/{username}/attestations/{attestation_id}/DELETE/path`. + public struct Path: Sendable, Hashable { + /// The handle for the GitHub user account. + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/{attestation_id}/DELETE/path/username`. + public var username: Components.Parameters.Username + /// Attestation ID + /// + /// - Remark: Generated from `#/paths/users/{username}/attestations/{attestation_id}/DELETE/path/attestation_id`. + public var attestationId: Swift.Int + /// Creates a new `Path`. + /// + /// - Parameters: + /// - username: The handle for the GitHub user account. + /// - attestationId: Attestation ID + public init( + username: Components.Parameters.Username, + attestationId: Swift.Int + ) { + self.username = username + self.attestationId = attestationId + } + } + public var path: Operations.UsersDeleteAttestationsById.Input.Path + /// - Remark: Generated from `#/paths/users/{username}/attestations/{attestation_id}/DELETE/header`. + public struct Headers: Sendable, Hashable { + public var accept: [OpenAPIRuntime.AcceptHeaderContentType] + /// Creates a new `Headers`. + /// + /// - Parameters: + /// - accept: + public init(accept: [OpenAPIRuntime.AcceptHeaderContentType] = .defaultValues()) { + self.accept = accept + } + } + public var headers: Operations.UsersDeleteAttestationsById.Input.Headers + /// Creates a new `Input`. + /// + /// - Parameters: + /// - path: + /// - headers: + public init( + path: Operations.UsersDeleteAttestationsById.Input.Path, + headers: Operations.UsersDeleteAttestationsById.Input.Headers = .init() + ) { + self.path = path + self.headers = headers + } + } + @frozen public enum Output: Sendable, Hashable { + public struct Ok: Sendable, Hashable { + /// Creates a new `Ok`. + public init() {} + } + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)/responses/200`. + /// + /// HTTP response code: `200 ok`. + case ok(Operations.UsersDeleteAttestationsById.Output.Ok) + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)/responses/200`. + /// + /// HTTP response code: `200 ok`. + public static var ok: Self { + .ok(.init()) + } + /// The associated value of the enum case if `self` is `.ok`. + /// + /// - Throws: An error if `self` is not `.ok`. + /// - SeeAlso: `.ok`. + public var ok: Operations.UsersDeleteAttestationsById.Output.Ok { + get throws { + switch self { + case let .ok(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "ok", + response: self + ) + } + } + } + public struct NoContent: Sendable, Hashable { + /// Creates a new `NoContent`. + public init() {} + } + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)/responses/204`. + /// + /// HTTP response code: `204 noContent`. + case noContent(Operations.UsersDeleteAttestationsById.Output.NoContent) + /// Response + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)/responses/204`. + /// + /// HTTP response code: `204 noContent`. + public static var noContent: Self { + .noContent(.init()) + } + /// The associated value of the enum case if `self` is `.noContent`. + /// + /// - Throws: An error if `self` is not `.noContent`. + /// - SeeAlso: `.noContent`. + public var noContent: Operations.UsersDeleteAttestationsById.Output.NoContent { + get throws { + switch self { + case let .noContent(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "noContent", + response: self + ) + } + } + } + /// Forbidden + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)/responses/403`. + /// + /// HTTP response code: `403 forbidden`. + case forbidden(Components.Responses.Forbidden) + /// The associated value of the enum case if `self` is `.forbidden`. + /// + /// - Throws: An error if `self` is not `.forbidden`. + /// - SeeAlso: `.forbidden`. + public var forbidden: Components.Responses.Forbidden { + get throws { + switch self { + case let .forbidden(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "forbidden", + response: self + ) + } + } + } + /// Resource not found + /// + /// - Remark: Generated from `#/paths//users/{username}/attestations/{attestation_id}/delete(users/delete-attestations-by-id)/responses/404`. + /// + /// HTTP response code: `404 notFound`. + case notFound(Components.Responses.NotFound) + /// The associated value of the enum case if `self` is `.notFound`. + /// + /// - Throws: An error if `self` is not `.notFound`. + /// - SeeAlso: `.notFound`. + public var notFound: Components.Responses.NotFound { + get throws { + switch self { + case let .notFound(response): + return response + default: + try throwUnexpectedResponseStatus( + expectedStatus: "notFound", + response: self + ) + } + } + } + /// Undocumented response. + /// + /// A response with a code that is not documented in the OpenAPI document. + case undocumented(statusCode: Swift.Int, OpenAPIRuntime.UndocumentedPayload) + } + @frozen public enum AcceptableContentType: AcceptableProtocol { + case json + case other(Swift.String) + public init?(rawValue: Swift.String) { + switch rawValue.lowercased() { + case "application/json": + self = .json + default: + self = .other(rawValue) + } + } + public var rawValue: Swift.String { + switch self { + case let .other(string): + return string + case .json: + return "application/json" + } + } + public static var allCases: [Self] { + [ + .json + ] + } + } + } /// List attestations /// /// List a collection of artifact attestations with a given subject digest that are associated with repositories owned by a user. From 95dd47a681613f897dc39a3f0903b4ac2fdc4152 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:32:38 +0000 Subject: [PATCH 16/17] Commit via running: make Sources/codespaces --- Sources/codespaces/Types.swift | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Sources/codespaces/Types.swift b/Sources/codespaces/Types.swift index 5cb6aec113..6fbdc1fad3 100644 --- a/Sources/codespaces/Types.swift +++ b/Sources/codespaces/Types.swift @@ -3237,6 +3237,30 @@ public enum Components { public var webCommitSignoffRequired: Swift.Bool? /// - Remark: Generated from `#/components/schemas/minimal-repository/security_and_analysis`. public var securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public struct CustomPropertiesPayload: Codable, Hashable, Sendable { + /// A container of undocumented properties. + public var additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer + /// Creates a new `CustomPropertiesPayload`. + /// + /// - Parameters: + /// - additionalProperties: A container of undocumented properties. + public init(additionalProperties: OpenAPIRuntime.OpenAPIObjectContainer = .init()) { + self.additionalProperties = additionalProperties + } + public init(from decoder: any Decoder) throws { + additionalProperties = try decoder.decodeAdditionalProperties(knownKeys: []) + } + public func encode(to encoder: any Encoder) throws { + try encoder.encodeAdditionalProperties(additionalProperties) + } + } + /// The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. + /// + /// - Remark: Generated from `#/components/schemas/minimal-repository/custom_properties`. + public var customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? /// Creates a new `MinimalRepository`. /// /// - Parameters: @@ -3327,6 +3351,7 @@ public enum Components { /// - allowForking: /// - webCommitSignoffRequired: /// - securityAndAnalysis: + /// - customProperties: The custom properties that were defined for the repository. The keys are the custom property names, and the values are the corresponding custom property values. public init( id: Swift.Int64, nodeId: Swift.String, @@ -3414,7 +3439,8 @@ public enum Components { watchers: Swift.Int? = nil, allowForking: Swift.Bool? = nil, webCommitSignoffRequired: Swift.Bool? = nil, - securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil + securityAndAnalysis: Components.Schemas.SecurityAndAnalysis? = nil, + customProperties: Components.Schemas.MinimalRepository.CustomPropertiesPayload? = nil ) { self.id = id self.nodeId = nodeId @@ -3503,6 +3529,7 @@ public enum Components { self.allowForking = allowForking self.webCommitSignoffRequired = webCommitSignoffRequired self.securityAndAnalysis = securityAndAnalysis + self.customProperties = customProperties } public enum CodingKeys: String, CodingKey { case id @@ -3592,6 +3619,7 @@ public enum Components { case allowForking = "allow_forking" case webCommitSignoffRequired = "web_commit_signoff_required" case securityAndAnalysis = "security_and_analysis" + case customProperties = "custom_properties" } } /// An object without any properties. From f9c60bd30b716660420148662ac895e2941703a9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 16 Jun 2025 22:33:02 +0000 Subject: [PATCH 17/17] Commit via running: make Sources/copilot --- Sources/copilot/Types.swift | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/Sources/copilot/Types.swift b/Sources/copilot/Types.swift index 887e63c624..5d8b339a1e 100644 --- a/Sources/copilot/Types.swift +++ b/Sources/copilot/Types.swift @@ -1221,12 +1221,16 @@ public enum Components { public var id: Swift.Int64 /// - Remark: Generated from `#/components/schemas/enterprise-team/name`. public var name: Swift.String + /// - Remark: Generated from `#/components/schemas/enterprise-team/description`. + public var description: Swift.String? /// - Remark: Generated from `#/components/schemas/enterprise-team/slug`. public var slug: Swift.String /// - Remark: Generated from `#/components/schemas/enterprise-team/url`. public var url: Swift.String /// - Remark: Generated from `#/components/schemas/enterprise-team/sync_to_organizations`. - public var syncToOrganizations: Swift.String + public var syncToOrganizations: Swift.String? + /// - Remark: Generated from `#/components/schemas/enterprise-team/organization_selection_type`. + public var organizationSelectionType: Swift.String? /// - Remark: Generated from `#/components/schemas/enterprise-team/group_id`. public var groupId: Swift.String? /// - Remark: Generated from `#/components/schemas/enterprise-team/group_name`. @@ -1244,9 +1248,11 @@ public enum Components { /// - Parameters: /// - id: /// - name: + /// - description: /// - slug: /// - url: /// - syncToOrganizations: + /// - organizationSelectionType: /// - groupId: /// - groupName: /// - htmlUrl: @@ -1256,9 +1262,11 @@ public enum Components { public init( id: Swift.Int64, name: Swift.String, + description: Swift.String? = nil, slug: Swift.String, url: Swift.String, - syncToOrganizations: Swift.String, + syncToOrganizations: Swift.String? = nil, + organizationSelectionType: Swift.String? = nil, groupId: Swift.String? = nil, groupName: Swift.String? = nil, htmlUrl: Swift.String, @@ -1268,9 +1276,11 @@ public enum Components { ) { self.id = id self.name = name + self.description = description self.slug = slug self.url = url self.syncToOrganizations = syncToOrganizations + self.organizationSelectionType = organizationSelectionType self.groupId = groupId self.groupName = groupName self.htmlUrl = htmlUrl @@ -1281,9 +1291,11 @@ public enum Components { public enum CodingKeys: String, CodingKey { case id case name + case description case slug case url case syncToOrganizations = "sync_to_organizations" + case organizationSelectionType = "organization_selection_type" case groupId = "group_id" case groupName = "group_name" case htmlUrl = "html_url"