Skip to content

Commit 274648c

Browse files
Merge pull request #47 from Wei18/dependabot/submodules/Submodule/github/rest-api-description-100282f
Bump Submodule/github/rest-api-description from `6c0baea` to `100282f`
2 parents 5f7a067 + 3bff9a1 commit 274648c

File tree

3 files changed

+169
-7
lines changed

3 files changed

+169
-7
lines changed

Sources/orgs/Client.swift

+22
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,17 @@ public struct Client: APIProtocol {
134134
///
135135
/// To see the full details about an organization, the authenticated user must be an organization owner.
136136
///
137+
/// The values returned by this endpoint are set by the "Update an organization" endpoint. If your organization set a default security configuration (beta), the following values retrieved from the "Update an organization" endpoint have been overwritten by that configuration:
138+
///
139+
/// - advanced_security_enabled_for_new_repositories
140+
/// - dependabot_alerts_enabled_for_new_repositories
141+
/// - dependabot_security_updates_enabled_for_new_repositories
142+
/// - dependency_graph_enabled_for_new_repositories
143+
/// - secret_scanning_enabled_for_new_repositories
144+
/// - secret_scanning_push_protection_enabled_for_new_repositories
145+
///
146+
/// For more information on security configurations, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
147+
///
137148
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.
138149
///
139150
/// To see information about an organization's GitHub plan, GitHub Apps need the `Organization plan` permission.
@@ -226,6 +237,17 @@ public struct Client: APIProtocol {
226237
///
227238
/// Updates the organization's profile and member privileges.
228239
///
240+
/// With security configurations (beta), your organization can choose a default security configuration which will automatically apply a set of security enablement settings to new repositories in your organization based on their visibility. For targeted repositories, the following attributes will be overridden by the default security configuration:
241+
///
242+
/// - advanced_security_enabled_for_new_repositories
243+
/// - dependabot_alerts_enabled_for_new_repositories
244+
/// - dependabot_security_updates_enabled_for_new_repositories
245+
/// - dependency_graph_enabled_for_new_repositories
246+
/// - secret_scanning_enabled_for_new_repositories
247+
/// - secret_scanning_push_protection_enabled_for_new_repositories
248+
///
249+
/// For more information on setting a default security configuration, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
250+
///
229251
/// The authenticated user must be an organization owner to use this endpoint.
230252
///
231253
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` or `repo` scope to use this endpoint.

Sources/orgs/Types.swift

+146-6
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,17 @@ public protocol APIProtocol: Sendable {
2828
///
2929
/// To see the full details about an organization, the authenticated user must be an organization owner.
3030
///
31+
/// The values returned by this endpoint are set by the "Update an organization" endpoint. If your organization set a default security configuration (beta), the following values retrieved from the "Update an organization" endpoint have been overwritten by that configuration:
32+
///
33+
/// - advanced_security_enabled_for_new_repositories
34+
/// - dependabot_alerts_enabled_for_new_repositories
35+
/// - dependabot_security_updates_enabled_for_new_repositories
36+
/// - dependency_graph_enabled_for_new_repositories
37+
/// - secret_scanning_enabled_for_new_repositories
38+
/// - secret_scanning_push_protection_enabled_for_new_repositories
39+
///
40+
/// For more information on security configurations, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
41+
///
3142
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.
3243
///
3344
/// To see information about an organization's GitHub plan, GitHub Apps need the `Organization plan` permission.
@@ -41,6 +52,17 @@ public protocol APIProtocol: Sendable {
4152
///
4253
/// Updates the organization's profile and member privileges.
4354
///
55+
/// With security configurations (beta), your organization can choose a default security configuration which will automatically apply a set of security enablement settings to new repositories in your organization based on their visibility. For targeted repositories, the following attributes will be overridden by the default security configuration:
56+
///
57+
/// - advanced_security_enabled_for_new_repositories
58+
/// - dependabot_alerts_enabled_for_new_repositories
59+
/// - dependabot_security_updates_enabled_for_new_repositories
60+
/// - dependency_graph_enabled_for_new_repositories
61+
/// - secret_scanning_enabled_for_new_repositories
62+
/// - secret_scanning_push_protection_enabled_for_new_repositories
63+
///
64+
/// For more information on setting a default security configuration, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
65+
///
4466
/// The authenticated user must be an organization owner to use this endpoint.
4567
///
4668
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` or `repo` scope to use this endpoint.
@@ -810,6 +832,17 @@ extension APIProtocol {
810832
///
811833
/// To see the full details about an organization, the authenticated user must be an organization owner.
812834
///
835+
/// The values returned by this endpoint are set by the "Update an organization" endpoint. If your organization set a default security configuration (beta), the following values retrieved from the "Update an organization" endpoint have been overwritten by that configuration:
836+
///
837+
/// - advanced_security_enabled_for_new_repositories
838+
/// - dependabot_alerts_enabled_for_new_repositories
839+
/// - dependabot_security_updates_enabled_for_new_repositories
840+
/// - dependency_graph_enabled_for_new_repositories
841+
/// - secret_scanning_enabled_for_new_repositories
842+
/// - secret_scanning_push_protection_enabled_for_new_repositories
843+
///
844+
/// For more information on security configurations, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
845+
///
813846
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.
814847
///
815848
/// To see information about an organization's GitHub plan, GitHub Apps need the `Organization plan` permission.
@@ -831,6 +864,17 @@ extension APIProtocol {
831864
///
832865
/// Updates the organization's profile and member privileges.
833866
///
867+
/// With security configurations (beta), your organization can choose a default security configuration which will automatically apply a set of security enablement settings to new repositories in your organization based on their visibility. For targeted repositories, the following attributes will be overridden by the default security configuration:
868+
///
869+
/// - advanced_security_enabled_for_new_repositories
870+
/// - dependabot_alerts_enabled_for_new_repositories
871+
/// - dependabot_security_updates_enabled_for_new_repositories
872+
/// - dependency_graph_enabled_for_new_repositories
873+
/// - secret_scanning_enabled_for_new_repositories
874+
/// - secret_scanning_push_protection_enabled_for_new_repositories
875+
///
876+
/// For more information on setting a default security configuration, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
877+
///
834878
/// The authenticated user must be an organization owner to use this endpoint.
835879
///
836880
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` or `repo` scope to use this endpoint.
@@ -6428,7 +6472,44 @@ public enum Components {
64286472
/// Default value of the property
64296473
///
64306474
/// - Remark: Generated from `#/components/schemas/org-custom-property/default_value`.
6431-
public var default_value: Swift.String?
6475+
@frozen public enum default_valuePayload: Codable, Hashable, Sendable {
6476+
/// - Remark: Generated from `#/components/schemas/org-custom-property/default_value/case1`.
6477+
case case1(Swift.String)
6478+
/// - Remark: Generated from `#/components/schemas/org-custom-property/default_value/case2`.
6479+
case case2([Swift.String])
6480+
public init(from decoder: any Decoder) throws {
6481+
var errors: [any Error] = []
6482+
do {
6483+
self = .case1(try decoder.decodeFromSingleValueContainer())
6484+
return
6485+
} catch {
6486+
errors.append(error)
6487+
}
6488+
do {
6489+
self = .case2(try decoder.decodeFromSingleValueContainer())
6490+
return
6491+
} catch {
6492+
errors.append(error)
6493+
}
6494+
throw Swift.DecodingError.failedToDecodeOneOfSchema(
6495+
type: Self.self,
6496+
codingPath: decoder.codingPath,
6497+
errors: errors
6498+
)
6499+
}
6500+
public func encode(to encoder: any Encoder) throws {
6501+
switch self {
6502+
case let .case1(value):
6503+
try encoder.encodeToSingleValueContainer(value)
6504+
case let .case2(value):
6505+
try encoder.encodeToSingleValueContainer(value)
6506+
}
6507+
}
6508+
}
6509+
/// Default value of the property
6510+
///
6511+
/// - Remark: Generated from `#/components/schemas/org-custom-property/default_value`.
6512+
public var default_value: Components.Schemas.org_hyphen_custom_hyphen_property.default_valuePayload?
64326513
/// Short description of the property
64336514
///
64346515
/// - Remark: Generated from `#/components/schemas/org-custom-property/description`.
@@ -6463,7 +6544,7 @@ public enum Components {
64636544
property_name: Swift.String,
64646545
value_type: Components.Schemas.org_hyphen_custom_hyphen_property.value_typePayload,
64656546
required: Swift.Bool? = nil,
6466-
default_value: Swift.String? = nil,
6547+
default_value: Components.Schemas.org_hyphen_custom_hyphen_property.default_valuePayload? = nil,
64676548
description: Swift.String? = nil,
64686549
allowed_values: [Swift.String]? = nil,
64696550
values_editable_by: Components.Schemas.org_hyphen_custom_hyphen_property.values_editable_byPayload? = nil
@@ -7270,6 +7351,17 @@ public enum Operations {
72707351
///
72717352
/// To see the full details about an organization, the authenticated user must be an organization owner.
72727353
///
7354+
/// The values returned by this endpoint are set by the "Update an organization" endpoint. If your organization set a default security configuration (beta), the following values retrieved from the "Update an organization" endpoint have been overwritten by that configuration:
7355+
///
7356+
/// - advanced_security_enabled_for_new_repositories
7357+
/// - dependabot_alerts_enabled_for_new_repositories
7358+
/// - dependabot_security_updates_enabled_for_new_repositories
7359+
/// - dependency_graph_enabled_for_new_repositories
7360+
/// - secret_scanning_enabled_for_new_repositories
7361+
/// - secret_scanning_push_protection_enabled_for_new_repositories
7362+
///
7363+
/// For more information on security configurations, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
7364+
///
72737365
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.
72747366
///
72757367
/// To see information about an organization's GitHub plan, GitHub Apps need the `Organization plan` permission.
@@ -7431,6 +7523,17 @@ public enum Operations {
74317523
///
74327524
/// Updates the organization's profile and member privileges.
74337525
///
7526+
/// With security configurations (beta), your organization can choose a default security configuration which will automatically apply a set of security enablement settings to new repositories in your organization based on their visibility. For targeted repositories, the following attributes will be overridden by the default security configuration:
7527+
///
7528+
/// - advanced_security_enabled_for_new_repositories
7529+
/// - dependabot_alerts_enabled_for_new_repositories
7530+
/// - dependabot_security_updates_enabled_for_new_repositories
7531+
/// - dependency_graph_enabled_for_new_repositories
7532+
/// - secret_scanning_enabled_for_new_repositories
7533+
/// - secret_scanning_push_protection_enabled_for_new_repositories
7534+
///
7535+
/// For more information on setting a default security configuration, see "[Enabling security features at scale](https://docs.github.com/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale)."
7536+
///
74347537
/// The authenticated user must be an organization owner to use this endpoint.
74357538
///
74367539
/// OAuth app tokens and personal access tokens (classic) need the `admin:org` or `repo` scope to use this endpoint.
@@ -7495,7 +7598,7 @@ public enum Operations {
74957598
///
74967599
/// - Remark: Generated from `#/paths/orgs/{org}/PATCH/requestBody/json/name`.
74977600
public var name: Swift.String?
7498-
/// The description of the company.
7601+
/// The description of the company. The maximum size is 160 characters.
74997602
///
75007603
/// - Remark: Generated from `#/paths/orgs/{org}/PATCH/requestBody/json/description`.
75017604
public var description: Swift.String?
@@ -7637,7 +7740,7 @@ public enum Operations {
76377740
/// - twitter_username: The Twitter username of the company.
76387741
/// - location: The location.
76397742
/// - name: The shorthand name of the company.
7640-
/// - description: The description of the company.
7743+
/// - description: The description of the company. The maximum size is 160 characters.
76417744
/// - has_organization_projects: Whether an organization can use organization projects.
76427745
/// - has_repository_projects: Whether repositories that belong to the organization can use repository projects.
76437746
/// - default_repository_permission: Default permission level members have for organization repositories.
@@ -18937,7 +19040,44 @@ public enum Operations {
1893719040
/// Default value of the property
1893819041
///
1893919042
/// - Remark: Generated from `#/paths/orgs/{org}/properties/schema/{custom_property_name}/PUT/requestBody/json/default_value`.
18940-
public var default_value: Swift.String?
19043+
@frozen public enum default_valuePayload: Codable, Hashable, Sendable {
19044+
/// - Remark: Generated from `#/paths/orgs/{org}/properties/schema/{custom_property_name}/PUT/requestBody/json/default_value/case1`.
19045+
case case1(Swift.String)
19046+
/// - Remark: Generated from `#/paths/orgs/{org}/properties/schema/{custom_property_name}/PUT/requestBody/json/default_value/case2`.
19047+
case case2([Swift.String])
19048+
public init(from decoder: any Decoder) throws {
19049+
var errors: [any Error] = []
19050+
do {
19051+
self = .case1(try decoder.decodeFromSingleValueContainer())
19052+
return
19053+
} catch {
19054+
errors.append(error)
19055+
}
19056+
do {
19057+
self = .case2(try decoder.decodeFromSingleValueContainer())
19058+
return
19059+
} catch {
19060+
errors.append(error)
19061+
}
19062+
throw Swift.DecodingError.failedToDecodeOneOfSchema(
19063+
type: Self.self,
19064+
codingPath: decoder.codingPath,
19065+
errors: errors
19066+
)
19067+
}
19068+
public func encode(to encoder: any Encoder) throws {
19069+
switch self {
19070+
case let .case1(value):
19071+
try encoder.encodeToSingleValueContainer(value)
19072+
case let .case2(value):
19073+
try encoder.encodeToSingleValueContainer(value)
19074+
}
19075+
}
19076+
}
19077+
/// Default value of the property
19078+
///
19079+
/// - Remark: Generated from `#/paths/orgs/{org}/properties/schema/{custom_property_name}/PUT/requestBody/json/default_value`.
19080+
public var default_value: Operations.orgs_sol_create_hyphen_or_hyphen_update_hyphen_custom_hyphen_property.Input.Body.jsonPayload.default_valuePayload?
1894119081
/// Short description of the property
1894219082
///
1894319083
/// - Remark: Generated from `#/paths/orgs/{org}/properties/schema/{custom_property_name}/PUT/requestBody/json/description`.
@@ -18958,7 +19098,7 @@ public enum Operations {
1895819098
public init(
1895919099
value_type: Operations.orgs_sol_create_hyphen_or_hyphen_update_hyphen_custom_hyphen_property.Input.Body.jsonPayload.value_typePayload,
1896019100
required: Swift.Bool? = nil,
18961-
default_value: Swift.String? = nil,
19101+
default_value: Operations.orgs_sol_create_hyphen_or_hyphen_update_hyphen_custom_hyphen_property.Input.Body.jsonPayload.default_valuePayload? = nil,
1896219102
description: Swift.String? = nil,
1896319103
allowed_values: [Swift.String]? = nil
1896419104
) {

0 commit comments

Comments
 (0)