Skip to content

Commit aa5ddc6

Browse files
Merge pull request #87 from Wei18/dependabot/submodules/Submodule/github/rest-api-description-a0508ce
Bump Submodule/github/rest-api-description from `4162f99` to `a0508ce`
2 parents e078dd4 + 502d883 commit aa5ddc6

File tree

7 files changed

+162
-13
lines changed

7 files changed

+162
-13
lines changed

Sources/apps/Client.swift

-2
Original file line numberDiff line numberDiff line change
@@ -1080,8 +1080,6 @@ public struct Client: APIProtocol {
10801080
///
10811081
/// Optionally, use the `permissions` body parameter to specify the permissions that the installation access token should have. If `permissions` is not specified, the installation access token will have all of the permissions that were granted to the app. The installation access token cannot be granted permissions that the app was not granted.
10821082
///
1083-
/// When using the repository or permission parameters to reduce the access of the token, the complexity of the token is increased due to both the number of permissions in the request and the number of repositories the token will have access to. If the complexity is too large, the token will fail to be issued. If this occurs, the error message will indicate the maximum number of repositories that should be requested. For the average application requesting 8 permissions, this limit is around 5000 repositories. With fewer permissions requested, more repositories are supported.
1084-
///
10851083
/// You must use a [JWT](https://docs.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.
10861084
///
10871085
/// - Remark: HTTP `POST /app/installations/{installation_id}/access_tokens`.

Sources/apps/Types.swift

-6
Original file line numberDiff line numberDiff line change
@@ -114,8 +114,6 @@ public protocol APIProtocol: Sendable {
114114
///
115115
/// Optionally, use the `permissions` body parameter to specify the permissions that the installation access token should have. If `permissions` is not specified, the installation access token will have all of the permissions that were granted to the app. The installation access token cannot be granted permissions that the app was not granted.
116116
///
117-
/// When using the repository or permission parameters to reduce the access of the token, the complexity of the token is increased due to both the number of permissions in the request and the number of repositories the token will have access to. If the complexity is too large, the token will fail to be issued. If this occurs, the error message will indicate the maximum number of repositories that should be requested. For the average application requesting 8 permissions, this limit is around 5000 repositories. With fewer permissions requested, more repositories are supported.
118-
///
119117
/// You must use a [JWT](https://docs.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.
120118
///
121119
/// - Remark: HTTP `POST /app/installations/{installation_id}/access_tokens`.
@@ -521,8 +519,6 @@ extension APIProtocol {
521519
///
522520
/// Optionally, use the `permissions` body parameter to specify the permissions that the installation access token should have. If `permissions` is not specified, the installation access token will have all of the permissions that were granted to the app. The installation access token cannot be granted permissions that the app was not granted.
523521
///
524-
/// When using the repository or permission parameters to reduce the access of the token, the complexity of the token is increased due to both the number of permissions in the request and the number of repositories the token will have access to. If the complexity is too large, the token will fail to be issued. If this occurs, the error message will indicate the maximum number of repositories that should be requested. For the average application requesting 8 permissions, this limit is around 5000 repositories. With fewer permissions requested, more repositories are supported.
525-
///
526522
/// You must use a [JWT](https://docs.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.
527523
///
528524
/// - Remark: HTTP `POST /app/installations/{installation_id}/access_tokens`.
@@ -6901,8 +6897,6 @@ public enum Operations {
69016897
///
69026898
/// Optionally, use the `permissions` body parameter to specify the permissions that the installation access token should have. If `permissions` is not specified, the installation access token will have all of the permissions that were granted to the app. The installation access token cannot be granted permissions that the app was not granted.
69036899
///
6904-
/// When using the repository or permission parameters to reduce the access of the token, the complexity of the token is increased due to both the number of permissions in the request and the number of repositories the token will have access to. If the complexity is too large, the token will fail to be issued. If this occurs, the error message will indicate the maximum number of repositories that should be requested. For the average application requesting 8 permissions, this limit is around 5000 repositories. With fewer permissions requested, more repositories are supported.
6905-
///
69066900
/// You must use a [JWT](https://docs.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.
69076901
///
69086902
/// - Remark: HTTP `POST /app/installations/{installation_id}/access_tokens`.

Sources/orgs/Types.swift

+89
Original file line numberDiff line numberDiff line change
@@ -6448,6 +6448,32 @@ public enum Components {
64486448
///
64496449
/// - Remark: Generated from `#/components/schemas/organization-role/description`.
64506450
public var description: Swift.String?
6451+
/// The system role from which this role inherits permissions.
6452+
///
6453+
/// - Remark: Generated from `#/components/schemas/organization-role/base_role`.
6454+
@frozen public enum base_rolePayload: String, Codable, Hashable, Sendable {
6455+
case read = "read"
6456+
case triage = "triage"
6457+
case write = "write"
6458+
case maintain = "maintain"
6459+
case admin = "admin"
6460+
}
6461+
/// The system role from which this role inherits permissions.
6462+
///
6463+
/// - Remark: Generated from `#/components/schemas/organization-role/base_role`.
6464+
public var base_role: Components.Schemas.organization_hyphen_role.base_rolePayload?
6465+
/// Source answers the question, "where did this role come from?"
6466+
///
6467+
/// - Remark: Generated from `#/components/schemas/organization-role/source`.
6468+
@frozen public enum sourcePayload: String, Codable, Hashable, Sendable {
6469+
case Organization = "Organization"
6470+
case Enterprise = "Enterprise"
6471+
case Predefined = "Predefined"
6472+
}
6473+
/// Source answers the question, "where did this role come from?"
6474+
///
6475+
/// - Remark: Generated from `#/components/schemas/organization-role/source`.
6476+
public var source: Components.Schemas.organization_hyphen_role.sourcePayload?
64516477
/// A list of permissions included in this role.
64526478
///
64536479
/// - Remark: Generated from `#/components/schemas/organization-role/permissions`.
@@ -6468,6 +6494,8 @@ public enum Components {
64686494
/// - id: The unique identifier of the role.
64696495
/// - name: The name of the role.
64706496
/// - description: A short description about who this role is for or what permissions it grants.
6497+
/// - base_role: The system role from which this role inherits permissions.
6498+
/// - source: Source answers the question, "where did this role come from?"
64716499
/// - permissions: A list of permissions included in this role.
64726500
/// - organization:
64736501
/// - created_at: The date and time the role was created.
@@ -6476,6 +6504,8 @@ public enum Components {
64766504
id: Swift.Int64,
64776505
name: Swift.String,
64786506
description: Swift.String? = nil,
6507+
base_role: Components.Schemas.organization_hyphen_role.base_rolePayload? = nil,
6508+
source: Components.Schemas.organization_hyphen_role.sourcePayload? = nil,
64796509
permissions: [Swift.String],
64806510
organization: Components.Schemas.nullable_hyphen_simple_hyphen_user? = nil,
64816511
created_at: Foundation.Date,
@@ -6484,6 +6514,8 @@ public enum Components {
64846514
self.id = id
64856515
self.name = name
64866516
self.description = description
6517+
self.base_role = base_role
6518+
self.source = source
64876519
self.permissions = permissions
64886520
self.organization = organization
64896521
self.created_at = created_at
@@ -6493,6 +6525,8 @@ public enum Components {
64936525
case id
64946526
case name
64956527
case description
6528+
case base_role
6529+
case source
64966530
case permissions
64976531
case organization
64986532
case created_at
@@ -6503,6 +6537,18 @@ public enum Components {
65036537
///
65046538
/// - Remark: Generated from `#/components/schemas/team-role-assignment`.
65056539
public struct team_hyphen_role_hyphen_assignment: Codable, Hashable, Sendable {
6540+
/// Determines if the team has a direct, indirect, or mixed relationship to a role
6541+
///
6542+
/// - Remark: Generated from `#/components/schemas/team-role-assignment/assignment`.
6543+
@frozen public enum assignmentPayload: String, Codable, Hashable, Sendable {
6544+
case direct = "direct"
6545+
case indirect = "indirect"
6546+
case mixed = "mixed"
6547+
}
6548+
/// Determines if the team has a direct, indirect, or mixed relationship to a role
6549+
///
6550+
/// - Remark: Generated from `#/components/schemas/team-role-assignment/assignment`.
6551+
public var assignment: Components.Schemas.team_hyphen_role_hyphen_assignment.assignmentPayload?
65066552
/// - Remark: Generated from `#/components/schemas/team-role-assignment/id`.
65076553
public var id: Swift.Int
65086554
/// - Remark: Generated from `#/components/schemas/team-role-assignment/node_id`.
@@ -6575,6 +6621,7 @@ public enum Components {
65756621
/// Creates a new `team_hyphen_role_hyphen_assignment`.
65766622
///
65776623
/// - Parameters:
6624+
/// - assignment: Determines if the team has a direct, indirect, or mixed relationship to a role
65786625
/// - id:
65796626
/// - node_id:
65806627
/// - name:
@@ -6590,6 +6637,7 @@ public enum Components {
65906637
/// - repositories_url:
65916638
/// - parent:
65926639
public init(
6640+
assignment: Components.Schemas.team_hyphen_role_hyphen_assignment.assignmentPayload? = nil,
65936641
id: Swift.Int,
65946642
node_id: Swift.String,
65956643
name: Swift.String,
@@ -6605,6 +6653,7 @@ public enum Components {
66056653
repositories_url: Swift.String,
66066654
parent: Components.Schemas.nullable_hyphen_team_hyphen_simple? = nil
66076655
) {
6656+
self.assignment = assignment
66086657
self.id = id
66096658
self.node_id = node_id
66106659
self.name = name
@@ -6621,6 +6670,7 @@ public enum Components {
66216670
self.parent = parent
66226671
}
66236672
public enum CodingKeys: String, CodingKey {
6673+
case assignment
66246674
case id
66256675
case node_id
66266676
case name
@@ -6748,6 +6798,22 @@ public enum Components {
67486798
///
67496799
/// - Remark: Generated from `#/components/schemas/user-role-assignment`.
67506800
public struct user_hyphen_role_hyphen_assignment: Codable, Hashable, Sendable {
6801+
/// Determines if the user has a direct, indirect, or mixed relationship to a role
6802+
///
6803+
/// - Remark: Generated from `#/components/schemas/user-role-assignment/assignment`.
6804+
@frozen public enum assignmentPayload: String, Codable, Hashable, Sendable {
6805+
case direct = "direct"
6806+
case indirect = "indirect"
6807+
case mixed = "mixed"
6808+
}
6809+
/// Determines if the user has a direct, indirect, or mixed relationship to a role
6810+
///
6811+
/// - Remark: Generated from `#/components/schemas/user-role-assignment/assignment`.
6812+
public var assignment: Components.Schemas.user_hyphen_role_hyphen_assignment.assignmentPayload?
6813+
/// Team the user has gotten the role through
6814+
///
6815+
/// - Remark: Generated from `#/components/schemas/user-role-assignment/inherited_from`.
6816+
public var inherited_from: [Components.Schemas.team_hyphen_simple]?
67516817
/// - Remark: Generated from `#/components/schemas/user-role-assignment/name`.
67526818
public var name: Swift.String?
67536819
/// - Remark: Generated from `#/components/schemas/user-role-assignment/email`.
@@ -6795,6 +6861,8 @@ public enum Components {
67956861
/// Creates a new `user_hyphen_role_hyphen_assignment`.
67966862
///
67976863
/// - Parameters:
6864+
/// - assignment: Determines if the user has a direct, indirect, or mixed relationship to a role
6865+
/// - inherited_from: Team the user has gotten the role through
67986866
/// - name:
67996867
/// - email:
68006868
/// - login:
@@ -6818,6 +6886,8 @@ public enum Components {
68186886
/// - starred_at:
68196887
/// - user_view_type:
68206888
public init(
6889+
assignment: Components.Schemas.user_hyphen_role_hyphen_assignment.assignmentPayload? = nil,
6890+
inherited_from: [Components.Schemas.team_hyphen_simple]? = nil,
68216891
name: Swift.String? = nil,
68226892
email: Swift.String? = nil,
68236893
login: Swift.String,
@@ -6841,6 +6911,8 @@ public enum Components {
68416911
starred_at: Swift.String? = nil,
68426912
user_view_type: Swift.String? = nil
68436913
) {
6914+
self.assignment = assignment
6915+
self.inherited_from = inherited_from
68446916
self.name = name
68456917
self.email = email
68466918
self.login = login
@@ -6865,6 +6937,8 @@ public enum Components {
68656937
self.user_view_type = user_view_type
68666938
}
68676939
public enum CodingKeys: String, CodingKey {
6940+
case assignment
6941+
case inherited_from
68686942
case name
68696943
case email
68706944
case login
@@ -7293,6 +7367,17 @@ public enum Components {
72937367
///
72947368
/// - Remark: Generated from `#/components/schemas/custom-property/url`.
72957369
public var url: Swift.String?
7370+
/// The source type of the property
7371+
///
7372+
/// - Remark: Generated from `#/components/schemas/custom-property/source_type`.
7373+
@frozen public enum source_typePayload: String, Codable, Hashable, Sendable {
7374+
case organization = "organization"
7375+
case enterprise = "enterprise"
7376+
}
7377+
/// The source type of the property
7378+
///
7379+
/// - Remark: Generated from `#/components/schemas/custom-property/source_type`.
7380+
public var source_type: Components.Schemas.custom_hyphen_property.source_typePayload?
72967381
/// The type of the value for the property
72977382
///
72987383
/// - Remark: Generated from `#/components/schemas/custom-property/value_type`.
@@ -7376,6 +7461,7 @@ public enum Components {
73767461
/// - Parameters:
73777462
/// - property_name: The name of the property
73787463
/// - url: The URL that can be used to fetch, update, or delete info about this property via the API.
7464+
/// - source_type: The source type of the property
73797465
/// - value_type: The type of the value for the property
73807466
/// - required: Whether the property is required.
73817467
/// - default_value: Default value of the property
@@ -7385,6 +7471,7 @@ public enum Components {
73857471
public init(
73867472
property_name: Swift.String,
73877473
url: Swift.String? = nil,
7474+
source_type: Components.Schemas.custom_hyphen_property.source_typePayload? = nil,
73887475
value_type: Components.Schemas.custom_hyphen_property.value_typePayload,
73897476
required: Swift.Bool? = nil,
73907477
default_value: Components.Schemas.custom_hyphen_property.default_valuePayload? = nil,
@@ -7394,6 +7481,7 @@ public enum Components {
73947481
) {
73957482
self.property_name = property_name
73967483
self.url = url
7484+
self.source_type = source_type
73977485
self.value_type = value_type
73987486
self.required = required
73997487
self.default_value = default_value
@@ -7404,6 +7492,7 @@ public enum Components {
74047492
public enum CodingKeys: String, CodingKey {
74057493
case property_name
74067494
case url
7495+
case source_type
74077496
case value_type
74087497
case required
74097498
case default_value

Sources/repos/Client.swift

+7-1
Original file line numberDiff line numberDiff line change
@@ -15145,7 +15145,13 @@ public struct Client: APIProtocol {
1514515145
}
1514615146
/// Get a release asset
1514715147
///
15148-
/// To download the asset's binary content, set the `Accept` header of the request to [`application/octet-stream`](https://docs.github.com/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types). The API will either redirect the client to the location, or stream it directly if possible. API clients should handle both a `200` or `302` response.
15148+
/// To download the asset's binary content:
15149+
///
15150+
/// - If within a browser, fetch the location specified in the `browser_download_url` key provided in the response.
15151+
/// - Alternatively, set the `Accept` header of the request to
15152+
/// [`application/octet-stream`](https://docs.github.com/rest/using-the-rest-api/getting-started-with-the-rest-api#media-types).
15153+
/// The API will either redirect the client to the location, or stream it directly if possible.
15154+
/// API clients should handle both a `200` or `302` response.
1514915155
///
1515015156
/// - Remark: HTTP `GET /repos/{owner}/{repo}/releases/assets/{asset_id}`.
1515115157
/// - Remark: Generated from `#/paths//repos/{owner}/{repo}/releases/assets/{asset_id}/get(repos/get-release-asset)`.

0 commit comments

Comments
 (0)