From 4a87523b3fe593fc20d116a4662186682052faff Mon Sep 17 00:00:00 2001 From: WyriHaximus <147145+WyriHaximus@users.noreply.github.com> Date: Tue, 8 Oct 2024 16:57:13 +0000 Subject: [PATCH] [GitHub] Update to 1.1.4-c6249831ad99957f8d160f21b8d426dd from 1.1.4-24f4c3ebacf1ca5821698e28d77d32d1 Detected Schema changes: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ``` ├─┬Paths │ ├─┬/orgs/{org}/copilot/billing/seats │ │ └─┬GET │ │ └─┬Responses │ │ └─┬200 │ │ └─┬application/json │ │ └─┬default │ │ └──[🔀] value (199332:9) │ ├─┬/orgs/{org}/members/{username}/copilot │ │ └─┬GET │ │ └─┬Responses │ │ └─┬200 │ │ └─┬application/json │ │ └─┬default │ │ ├──[🔀] value (203430:9) │ │ └──[➖] value (203448:9) │ ├─┬/enterprises/{enterprise}/copilot/billing/seats │ │ └─┬GET │ │ └─┬Responses │ │ └─┬200 │ │ └─┬application/json │ │ └─┬default │ │ └──[🔀] value (199332:9) │ └─┬/orgs/{org}/copilot/billing │ └─┬GET │ └─┬Responses │ └─┬200 │ └─┬application/json │ └─┬default │ ├──[🔀] value (202912:9) │ ├──[🔀] value (202912:9) │ ├──[🔀] value (202912:9) │ ├──[🔀] value (202912:9) │ └──[➖] value (202929:9) └─┬Components ├─┬copilot-organization-details │ └──[➖] properties (72221:9)❌ └─┬copilot-seat-details └──[➖] properties (67568:9)❌ ``` | Document Element | Total Changes | Breaking Changes | |------------------|---------------|------------------| | paths | 9 | 0 | | components | 2 | 2 | Date: 10/08/24 | Commit: New: etc/specs/GitHub/previous.spec.yaml, Original: etc/specs/GitHub/current.spec.yaml - ❌ **BREAKING Changes**: _2_ out of _11_ - **Modifications**: _7_ - **Removals**: _4_ - **Breaking Removals**: _2_ ERROR: breaking changes discovered --- .../GitHub/etc/openapi-client-generator.state | 38 +++++++++---------- .../Operation/Orgs/Org/Copilot/Billing.php | 19 ++++++++++ .../Orgs/Org/Members/Username/Copilot.php | 19 ++++++++++ .../Orgs/CreateOrUpdateCustomProperty.php | 1 + .../Operator/Orgs/GetCustomProperty.php | 1 + .../Operator/Orgs/RemoveCustomProperty.php | 1 + .../src/Internal/Router/Delete/Orgs.php | 1 + .../GitHub/src/Internal/Router/Delete/Six.php | 1 - .../GitHub/src/Internal/Router/Get/Orgs.php | 1 + .../GitHub/src/Internal/Router/Get/Six.php | 2 +- .../GitHub/src/Internal/Router/Put/Orgs.php | 1 + .../GitHub/src/Internal/Router/Put/Six.php | 1 - clients/GitHub/src/Operation/Orgs.php | 3 ++ .../src/PHPStan/ClientCallReturnTypes.php | 6 +-- .../src/Schema/CopilotOrganizationDetails.php | 16 +++++++- .../GitHub/src/Schema/CopilotSeatDetails.php | 16 +++++++- .../Response/ApplicationJson/Ok.php | 15 +++++++- .../Response/ApplicationJson/Ok.php | 15 +++++++- .../tests/Types/ClientCallReturnTypes.php | 6 +-- etc/specs/GitHub/current.spec.yaml | 19 ++++++++++ 20 files changed, 146 insertions(+), 36 deletions(-) diff --git a/clients/GitHub/etc/openapi-client-generator.state b/clients/GitHub/etc/openapi-client-generator.state index 5ca212d3580..3e47cfbe420 100644 --- a/clients/GitHub/etc/openapi-client-generator.state +++ b/clients/GitHub/etc/openapi-client-generator.state @@ -1,5 +1,5 @@ { - "specHash": "24f4c3ebacf1ca5821698e28d77d32d1", + "specHash": "c6249831ad99957f8d160f21b8d426dd", "generatedFiles": { "files": [ { @@ -5576,7 +5576,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Orgs.php", - "hash": "a471065365c30c5de2e67c9b59762318" + "hash": "969f2d59467f854edc18a940b109cab4" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Actions.php", @@ -11668,15 +11668,15 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/CopilotOrganizationDetails.php", - "hash": "c7942b67efff87e3886a31a79eb0df76" + "hash": "2050773bcb76af8cf988458a3bfd22a1" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/CopilotSeatDetails.php", - "hash": "71f4354ce2e2195c0502b1c58685d270" + "hash": "a8ecbaf9a8ebe5dae05d80caf63adb7a" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/Operations\/Copilot\/ListCopilotSeats\/Response\/ApplicationJson\/Ok.php", - "hash": "1c08d3802ed3f5f09d489c90519b80ed" + "hash": "e44a3e6b789fe93c25429d29881b391a" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/AliasAbstract\/TietF5944C0A\/TietAA99D7D8\/Tiet9AE1F544\/TietA28F869C.php", @@ -24452,7 +24452,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Orgs.php", - "hash": "7625cb2f748a25f73eb436379d487943" + "hash": "7aa1e49892497be27649dd82f16073ed" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/RateLimit.php", @@ -24812,7 +24812,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/Orgs.php", - "hash": "f75d53cf3c1a759efc2dcff811581dfb" + "hash": "fc2e156a854552a3e4ab12a89471a39c" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/Teams.php", @@ -24872,7 +24872,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Put\/Orgs.php", - "hash": "b7064f19fd6b2132fea4c2076dc726d0" + "hash": "f216337da6ea505b2938bd94df3bda5c" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Put\/Codespaces.php", @@ -24956,7 +24956,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Six.php", - "hash": "343c2b760b84ced96a51118cca0661bb" + "hash": "b2a28a4c2a159a5554c4694f89317cfd" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Seven.php", @@ -25096,7 +25096,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/Six.php", - "hash": "08ccaed3cd1c6bf14a3562ee889d0655" + "hash": "ca355d92539b542ef91be76d2fb5450d" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/Eight.php", @@ -25128,7 +25128,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Put\/Six.php", - "hash": "005f520b7747dbc03aca2290b99d7037" + "hash": "9f3dc75023548d3071b5b9a37ecfcf6b" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Put\/Eight.php", @@ -25484,7 +25484,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Orgs\/Org\/Copilot\/Billing.php", - "hash": "2ee6e77d51da0181357404f7a6366cfd" + "hash": "ba0ebdf9ed5de7f8bbfe345861748d2c" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Orgs\/Org\/Copilot\/Billing\/Seats.php", @@ -25604,7 +25604,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Orgs\/Org\/Members\/Username\/Copilot.php", - "hash": "79a20fd637d2fecbf00f10bd42cb3147" + "hash": "c06f25e050a7238628e4d0f336795349" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Orgs\/Org\/Memberships\/Username.php", @@ -27528,7 +27528,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/Orgs\/GetCustomProperty.php", - "hash": "8dc202d2f5dfc5935acd69ac1bbdb0dd" + "hash": "6043440685746e826184b7017c073581" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/Orgs\/GetCustomPropertyTest.php", @@ -27540,7 +27540,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/Orgs\/CreateOrUpdateCustomProperty.php", - "hash": "e503ca6aa384e7f5366d52af6a340c75" + "hash": "0014f81ebf2c18215cdff0f91368e995" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/Orgs\/CreateOrUpdateCustomPropertyTest.php", @@ -27552,7 +27552,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/Orgs\/RemoveCustomProperty.php", - "hash": "b6f73478344e10109c8163f03d3ed6c5" + "hash": "8c1f0450066b826bd733d51dc3270205" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/Orgs\/RemoveCustomPropertyTest.php", @@ -27736,11 +27736,11 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/PHPStan\/ClientCallReturnTypes.php", - "hash": "e10489bd6c2a67db47e1033c7dbcc6f4" + "hash": "b279bfe420072ca3881b316b41cde25a" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Types\/ClientCallReturnTypes.php", - "hash": "61d8619e191abe5c0c8fd6bf572ad7cc" + "hash": "a3cd037b10acacb7fbfa8165f0c08dac" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/..\/etc\/phpstan-extension.neon", @@ -29576,7 +29576,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/Operations\/Copilot\/ListCopilotSeatsForEnterprise\/Response\/ApplicationJson\/Ok.php", - "hash": "9186b42a601359e27cb165753f1d9100" + "hash": "cb30e7a32b89dfe82a76b606ff934eb5" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Enterprises\/Enterprise\/Copilot\/Billing\/Seats.php", diff --git a/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Copilot/Billing.php b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Copilot/Billing.php index 99999596081..23d9a034044 100644 --- a/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Copilot/Billing.php +++ b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Copilot/Billing.php @@ -128,6 +128,17 @@ private function hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️Copi $properties['seatManagementSetting'] = $value; after_seatManagementSetting: + + $value = $payload['plan_type'] ?? null; + + if ($value === null) { + $properties['planType'] = null; + goto after_planType; + } + + $properties['planType'] = $value; + + after_planType: } catch (Throwable $exception) { throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\CopilotOrganizationDetails', $exception, stack: $this->hydrationStack); } @@ -426,6 +437,14 @@ private function serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema $seatManagementSetting = $object->seatManagementSetting; after_seatManagementSetting: $result['seat_management_setting'] = $seatManagementSetting; + $planType = $object->planType; + + if ($planType === null) { + goto after_planType; + } + + after_planType: $result['plan_type'] = $planType; + return $result; } diff --git a/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Members/Username/Copilot.php b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Members/Username/Copilot.php index d1ef75e81b5..78db3afebb4 100644 --- a/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Members/Username/Copilot.php +++ b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Members/Username/Copilot.php @@ -176,6 +176,17 @@ private function hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️Copi $properties['updatedAt'] = $value; after_updatedAt: + + $value = $payload['plan_type'] ?? null; + + if ($value === null) { + $properties['planType'] = null; + goto after_planType; + } + + $properties['planType'] = $value; + + after_planType: } catch (Throwable $exception) { throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\CopilotSeatDetails', $exception, stack: $this->hydrationStack); } @@ -817,6 +828,14 @@ private function serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema after_updatedAt: $result['updated_at'] = $updatedAt; + $planType = $object->planType; + + if ($planType === null) { + goto after_planType; + } + + after_planType: $result['plan_type'] = $planType; + return $result; } diff --git a/clients/GitHub/src/Internal/Operator/Orgs/CreateOrUpdateCustomProperty.php b/clients/GitHub/src/Internal/Operator/Orgs/CreateOrUpdateCustomProperty.php index 99d6f4adbcf..823a782717f 100644 --- a/clients/GitHub/src/Internal/Operator/Orgs/CreateOrUpdateCustomProperty.php +++ b/clients/GitHub/src/Internal/Operator/Orgs/CreateOrUpdateCustomProperty.php @@ -24,6 +24,7 @@ public function __construct(private Browser $browser, private AuthenticationInte { } + /** @return */ public function call(string $org, string $customPropertyName, array $params): CustomProperty { $operation = new \ApiClients\Client\GitHub\Internal\Operation\Orgs\CreateOrUpdateCustomProperty($this->requestSchemaValidator, $this->responseSchemaValidator, $this->hydrator, $org, $customPropertyName); diff --git a/clients/GitHub/src/Internal/Operator/Orgs/GetCustomProperty.php b/clients/GitHub/src/Internal/Operator/Orgs/GetCustomProperty.php index 4378784a67d..0a8b0a399fd 100644 --- a/clients/GitHub/src/Internal/Operator/Orgs/GetCustomProperty.php +++ b/clients/GitHub/src/Internal/Operator/Orgs/GetCustomProperty.php @@ -24,6 +24,7 @@ public function __construct(private Browser $browser, private AuthenticationInte { } + /** @return */ public function call(string $org, string $customPropertyName): CustomProperty { $operation = new \ApiClients\Client\GitHub\Internal\Operation\Orgs\GetCustomProperty($this->responseSchemaValidator, $this->hydrator, $org, $customPropertyName); diff --git a/clients/GitHub/src/Internal/Operator/Orgs/RemoveCustomProperty.php b/clients/GitHub/src/Internal/Operator/Orgs/RemoveCustomProperty.php index 0b5456f8299..6a7dbe70300 100644 --- a/clients/GitHub/src/Internal/Operator/Orgs/RemoveCustomProperty.php +++ b/clients/GitHub/src/Internal/Operator/Orgs/RemoveCustomProperty.php @@ -24,6 +24,7 @@ public function __construct(private Browser $browser, private AuthenticationInte { } + /** @return */ public function call(string $org, string $customPropertyName): WithoutBody { $operation = new \ApiClients\Client\GitHub\Internal\Operation\Orgs\RemoveCustomProperty($this->responseSchemaValidator, $this->hydrator, $org, $customPropertyName); diff --git a/clients/GitHub/src/Internal/Router/Delete/Orgs.php b/clients/GitHub/src/Internal/Router/Delete/Orgs.php index 16f87eda38a..ee6c6e11fe1 100644 --- a/clients/GitHub/src/Internal/Router/Delete/Orgs.php +++ b/clients/GitHub/src/Internal/Router/Delete/Orgs.php @@ -278,6 +278,7 @@ public function revokeAllOrgRolesUser(array $params): WithoutBody return $operator->call($arguments['org'], $arguments['username']); } + /** @return */ public function removeCustomProperty(array $params): WithoutBody { $arguments = []; diff --git a/clients/GitHub/src/Internal/Router/Delete/Six.php b/clients/GitHub/src/Internal/Router/Delete/Six.php index 3be687de8b9..11e7028dcba 100644 --- a/clients/GitHub/src/Internal/Router/Delete/Six.php +++ b/clients/GitHub/src/Internal/Router/Delete/Six.php @@ -18,7 +18,6 @@ public function __construct(private Routers $routers) { } - /** @return |\ApiClients\Tools\OpenApiClient\Utils\Response\WithoutBody */ public function call(string $call, array $params, array $pathChunks): WithoutBody|Ok|Json|ActionsCacheList|FileCommit { if ($pathChunks[0] === '') { diff --git a/clients/GitHub/src/Internal/Router/Get/Orgs.php b/clients/GitHub/src/Internal/Router/Get/Orgs.php index bdd3a94771c..c2558871da8 100644 --- a/clients/GitHub/src/Internal/Router/Get/Orgs.php +++ b/clients/GitHub/src/Internal/Router/Get/Orgs.php @@ -1006,6 +1006,7 @@ public function listPatGrantRepositories(array $params): iterable return $operator->call($arguments['org'], $arguments['pat_id'], $arguments['per_page'], $arguments['page']); } + /** @return */ public function getCustomProperty(array $params): CustomProperty { $arguments = []; diff --git a/clients/GitHub/src/Internal/Router/Get/Six.php b/clients/GitHub/src/Internal/Router/Get/Six.php index 2f4bb1d62cc..e60a802fe22 100644 --- a/clients/GitHub/src/Internal/Router/Get/Six.php +++ b/clients/GitHub/src/Internal/Router/Get/Six.php @@ -74,7 +74,7 @@ public function __construct(private Routers $routers) { } - /** @return |Observable|Observable|Observable|WithoutBody|Observable|Observable|Observable|Observable|Observable|Schema\CustomProperty|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Schema\Operations\Repos\GetCodeFrequencyStats\Response\ApplicationJson\Accepted\Application\Json|Observable|Schema\Operations\Repos\GetCommitActivityStats\Response\ApplicationJson\Accepted\Application\Json|Observable|Schema\Operations\Repos\GetContributorsStats\Response\ApplicationJson\Accepted\Application\Json|Observable|Observable|Observable|Observable|Observable */ + /** @return |Observable|Observable|Observable|WithoutBody|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Schema\Operations\Repos\GetCodeFrequencyStats\Response\ApplicationJson\Accepted\Application\Json|Observable|Schema\Operations\Repos\GetCommitActivityStats\Response\ApplicationJson\Accepted\Application\Json|Observable|Schema\Operations\Repos\GetContributorsStats\Response\ApplicationJson\Accepted\Application\Json|Observable|Observable|Observable|Observable|Observable */ public function call(string $call, array $params, array $pathChunks): Ok|iterable|ActionsCacheUsageOrgEnterprise|\ApiClients\Client\GitHub\Schema\Operations\Actions\GetActionsCacheUsageByRepoForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedRepositoriesEnabledGithubActionsOrganization\Response\ApplicationJson\Ok|SelectedActions|ActionsGetDefaultWorkflowPermissions|Runner|ActionsPublicKey|OrganizationActionsSecret|OrganizationActionsVariable|WithoutBody|CodeSecurityConfiguration|CodespacesPublicKey|CodespacesOrgSecret|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeats\Response\ApplicationJson\Ok|DependabotPublicKey|OrganizationDependabotSecret|WebhookConfig|Json|CopilotSeatDetails|Package|CustomProperty|RuleSuite|ActionsBillingUsage|PackagesBillingUsage|CombinedBillingUsage|ProjectCollaboratorPermission|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListArtifactsForRepo\Response\ApplicationJson\Ok|ActionsCacheList|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationVariables\Response\ApplicationJson\Ok|ActionsRepositoryPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoWorkflows\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListAttestations\Response\ApplicationJson\Ok\Application\Json|Autolink|BranchWithProtection|BasicError|CheckRun|CheckSuite|CodeScanningDefaultSetup|CodeownersErrors|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListDevcontainersInRepositoryForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\RepoMachinesForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\PreFlightWithRepoForAuthenticatedUser\Response\ApplicationJson\Ok|CodespacesPermissionsCheckForDevcontainer|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepoSecrets\Response\ApplicationJson\Ok|CommitComment|Commit|CommunityProfile|CommitComparison|ContentDirectory|ContentFile|ContentSymlink|ContentSubmodule|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListRepoSecrets\Response\ApplicationJson\Ok|DependencyGraphSpdxSbom|Deployment|Environment|Hook|Issue|DeployKey|Label|Milestone|PagesHealthCheck|EmptyObject|PullRequest|Release|RepositoryRuleset|RepositoryAdvisory|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetCodeFrequencyStats\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetCommitActivityStats\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetContributorsStats\Response\ApplicationJson\Accepted\Application\Json|ParticipationStats|CloneTraffic|ViewTraffic|TeamRepository|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepositoriesForSecretForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|CodespaceExportDetails { if ($pathChunks[0] === '') { diff --git a/clients/GitHub/src/Internal/Router/Put/Orgs.php b/clients/GitHub/src/Internal/Router/Put/Orgs.php index 97815d09b79..046e1e77af8 100644 --- a/clients/GitHub/src/Internal/Router/Put/Orgs.php +++ b/clients/GitHub/src/Internal/Router/Put/Orgs.php @@ -160,6 +160,7 @@ public function assignUserToOrgRole(array $params): WithoutBody return $operator->call($arguments['org'], $arguments['username'], $arguments['role_id']); } + /** @return */ public function createOrUpdateCustomProperty(array $params): CustomProperty { $arguments = []; diff --git a/clients/GitHub/src/Internal/Router/Put/Six.php b/clients/GitHub/src/Internal/Router/Put/Six.php index 3305f95faaf..af284384afe 100644 --- a/clients/GitHub/src/Internal/Router/Put/Six.php +++ b/clients/GitHub/src/Internal/Router/Put/Six.php @@ -20,7 +20,6 @@ public function __construct(private Routers $routers) { } - /** @return |Schema\CustomProperty */ public function call(string $call, array $params, array $pathChunks): WithoutBody|EmptyObject|CustomProperty|RepositoryInvitation|FileCommit|Environment|RepositoryRuleset { if ($pathChunks[0] === '') { diff --git a/clients/GitHub/src/Operation/Orgs.php b/clients/GitHub/src/Operation/Orgs.php index eb8343bb2b2..dc8ac3d0e64 100644 --- a/clients/GitHub/src/Operation/Orgs.php +++ b/clients/GitHub/src/Operation/Orgs.php @@ -432,16 +432,19 @@ public function createOrUpdateCustomProperties(string $org, array $params): iter return $this->operators->orgs👷CreateOrUpdateCustomProperties()->call($org, $params); } + /** @return */ public function getCustomProperty(string $org, string $customPropertyName): CustomProperty { return $this->operators->orgs👷GetCustomProperty()->call($org, $customPropertyName); } + /** @return */ public function createOrUpdateCustomProperty(string $org, string $customPropertyName, array $params): CustomProperty { return $this->operators->orgs👷CreateOrUpdateCustomProperty()->call($org, $customPropertyName, $params); } + /** @return */ public function removeCustomProperty(string $org, string $customPropertyName): WithoutBody { return $this->operators->orgs👷RemoveCustomProperty()->call($org, $customPropertyName); diff --git a/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php b/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php index 239b6280166..87997385669 100644 --- a/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php +++ b/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php @@ -1232,15 +1232,15 @@ public function getTypeFromMethodCall(MethodReflection $methodReflection, Method } if ($call === 'GET /orgs/{org}/properties/schema/{custom_property_name}') { - return $this->typeResolver->resolve('Schema\\CustomProperty'); + return $this->typeResolver->resolve(''); } if ($call === 'PUT /orgs/{org}/properties/schema/{custom_property_name}') { - return $this->typeResolver->resolve('Schema\\CustomProperty'); + return $this->typeResolver->resolve(''); } if ($call === 'DELETE /orgs/{org}/properties/schema/{custom_property_name}') { - return $this->typeResolver->resolve('\\ApiClients\\Tools\\OpenApiClient\\Utils\\Response\\WithoutBody'); + return $this->typeResolver->resolve(''); } if ($call === 'GET /orgs/{org}/properties/values') { diff --git a/clients/GitHub/src/Schema/CopilotOrganizationDetails.php b/clients/GitHub/src/Schema/CopilotOrganizationDetails.php index ca812325079..f12466c26c4 100644 --- a/clients/GitHub/src/Schema/CopilotOrganizationDetails.php +++ b/clients/GitHub/src/Schema/CopilotOrganizationDetails.php @@ -95,6 +95,15 @@ ], "type": "string", "description": "The mode of assigning new seats." + }, + "plan_type": { + "enum": [ + "business", + "enterprise", + "unknown" + ], + "type": "string", + "description": "The Copilot plan of the organization, or the parent enterprise, when applicable." } }, "description": "Information about the seat breakdown and policies set for an organization with a Copilot Business or Copilot Enterprise subscription.", @@ -115,7 +124,8 @@ "ide_chat": "unconfigured", "platform_chat": "enabled", "cli": "enabled", - "seat_management_setting": "assign_all" + "seat_management_setting": "assign_all", + "plan_type": "business" }'; /** @@ -125,13 +135,15 @@ * platformChat: The organization policy for allowing or disallowing organization members to use Copilot features within github.com. * cli: The organization policy for allowing or disallowing organization members to use Copilot within their CLI. * seatManagementSetting: The mode of assigning new seats. + * planType: The Copilot plan of the organization, or the parent enterprise, when applicable. */ public function __construct(#[MapFrom('seat_breakdown')] public Schema\CopilotSeatBreakdown $seatBreakdown, #[MapFrom('public_code_suggestions')] public string $publicCodeSuggestions, #[MapFrom('ide_chat')] public string|null $ideChat, #[MapFrom('platform_chat')] public string|null $platformChat, public string|null $cli, #[MapFrom('seat_management_setting')] - public string $seatManagementSetting,) + public string $seatManagementSetting, #[MapFrom('plan_type')] + public string|null $planType,) { } } diff --git a/clients/GitHub/src/Schema/CopilotSeatDetails.php b/clients/GitHub/src/Schema/CopilotSeatDetails.php index e43fd6a8c4a..058452bba33 100644 --- a/clients/GitHub/src/Schema/CopilotSeatDetails.php +++ b/clients/GitHub/src/Schema/CopilotSeatDetails.php @@ -602,6 +602,15 @@ "type": "string", "description": "Timestamp of when the assignee\'s GitHub Copilot access was last updated, in ISO 8601 format.", "format": "date-time" + }, + "plan_type": { + "enum": [ + "business", + "enterprise", + "unknown" + ], + "type": "string", + "description": "The Copilot plan of the organization, or the parent enterprise, when applicable." } }, "description": "Information about a Copilot Business seat assignment for a user, team, or organization.", @@ -652,7 +661,8 @@ "last_activity_at": "1970-01-01T00:00:00+00:00", "last_activity_editor": "generated", "created_at": "1970-01-01T00:00:00+00:00", - "updated_at": "1970-01-01T00:00:00+00:00" + "updated_at": "1970-01-01T00:00:00+00:00", + "plan_type": "business" }'; /** @@ -663,6 +673,7 @@ * lastActivityEditor: Last editor that was used by the user for a GitHub Copilot completion. * createdAt: Timestamp of when the assignee was last granted access to GitHub Copilot, in ISO 8601 format. * updatedAt: Timestamp of when the assignee's GitHub Copilot access was last updated, in ISO 8601 format. + * planType: The Copilot plan of the organization, or the parent enterprise, when applicable. */ public function __construct(public Schema\SimpleUser $assignee, public Schema\OrganizationSimple|null $organization, #[MapFrom('assigning_team')] #[AssigningTeam] @@ -671,7 +682,8 @@ public function __construct(public Schema\SimpleUser $assignee, public Schema\Or public string|null $lastActivityAt, #[MapFrom('last_activity_editor')] public string|null $lastActivityEditor, #[MapFrom('created_at')] public string $createdAt, #[MapFrom('updated_at')] - public string|null $updatedAt,) + public string|null $updatedAt, #[MapFrom('plan_type')] + public string|null $planType,) { } } diff --git a/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeats/Response/ApplicationJson/Ok.php b/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeats/Response/ApplicationJson/Ok.php index f14c8063da3..1bc6cf46c84 100644 --- a/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeats/Response/ApplicationJson/Ok.php +++ b/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeats/Response/ApplicationJson/Ok.php @@ -609,6 +609,15 @@ "type": "string", "description": "Timestamp of when the assignee\'s GitHub Copilot access was last updated, in ISO 8601 format.", "format": "date-time" + }, + "plan_type": { + "enum": [ + "business", + "enterprise", + "unknown" + ], + "type": "string", + "description": "The Copilot plan of the organization, or the parent enterprise, when applicable." } }, "description": "Information about a Copilot Business seat assignment for a user, team, or organization.", @@ -665,7 +674,8 @@ "last_activity_at": "1970-01-01T00:00:00+00:00", "last_activity_editor": "generated", "created_at": "1970-01-01T00:00:00+00:00", - "updated_at": "1970-01-01T00:00:00+00:00" + "updated_at": "1970-01-01T00:00:00+00:00", + "plan_type": "business" }, { "assignee": { @@ -710,7 +720,8 @@ "last_activity_at": "1970-01-01T00:00:00+00:00", "last_activity_editor": "generated", "created_at": "1970-01-01T00:00:00+00:00", - "updated_at": "1970-01-01T00:00:00+00:00" + "updated_at": "1970-01-01T00:00:00+00:00", + "plan_type": "business" } ] }'; diff --git a/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeatsForEnterprise/Response/ApplicationJson/Ok.php b/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeatsForEnterprise/Response/ApplicationJson/Ok.php index 0158e368a6c..8c93265999b 100644 --- a/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeatsForEnterprise/Response/ApplicationJson/Ok.php +++ b/clients/GitHub/src/Schema/Operations/Copilot/ListCopilotSeatsForEnterprise/Response/ApplicationJson/Ok.php @@ -609,6 +609,15 @@ "type": "string", "description": "Timestamp of when the assignee\'s GitHub Copilot access was last updated, in ISO 8601 format.", "format": "date-time" + }, + "plan_type": { + "enum": [ + "business", + "enterprise", + "unknown" + ], + "type": "string", + "description": "The Copilot plan of the organization, or the parent enterprise, when applicable." } }, "description": "Information about a Copilot Business seat assignment for a user, team, or organization.", @@ -665,7 +674,8 @@ "last_activity_at": "1970-01-01T00:00:00+00:00", "last_activity_editor": "generated", "created_at": "1970-01-01T00:00:00+00:00", - "updated_at": "1970-01-01T00:00:00+00:00" + "updated_at": "1970-01-01T00:00:00+00:00", + "plan_type": "business" }, { "assignee": { @@ -710,7 +720,8 @@ "last_activity_at": "1970-01-01T00:00:00+00:00", "last_activity_editor": "generated", "created_at": "1970-01-01T00:00:00+00:00", - "updated_at": "1970-01-01T00:00:00+00:00" + "updated_at": "1970-01-01T00:00:00+00:00", + "plan_type": "business" } ] }'; diff --git a/clients/GitHub/tests/Types/ClientCallReturnTypes.php b/clients/GitHub/tests/Types/ClientCallReturnTypes.php index cddffe6da31..7d6cb950726 100644 --- a/clients/GitHub/tests/Types/ClientCallReturnTypes.php +++ b/clients/GitHub/tests/Types/ClientCallReturnTypes.php @@ -314,9 +314,9 @@ function authHeader(): string assertType('', $client->call('POST /orgs/{org}/projects')); assertType('Observable', $client->call('GET /orgs/{org}/properties/schema')); assertType('Observable', $client->call('PATCH /orgs/{org}/properties/schema')); -assertType('Schema\\CustomProperty', $client->call('GET /orgs/{org}/properties/schema/{custom_property_name}')); -assertType('Schema\\CustomProperty', $client->call('PUT /orgs/{org}/properties/schema/{custom_property_name}')); -assertType('\\ApiClients\\Tools\\OpenApiClient\\Utils\\Response\\WithoutBody', $client->call('DELETE /orgs/{org}/properties/schema/{custom_property_name}')); +assertType('', $client->call('GET /orgs/{org}/properties/schema/{custom_property_name}')); +assertType('', $client->call('PUT /orgs/{org}/properties/schema/{custom_property_name}')); +assertType('', $client->call('DELETE /orgs/{org}/properties/schema/{custom_property_name}')); assertType('Observable', $client->call('GET /orgs/{org}/properties/values')); assertType('Observable', $client->call('LIST /orgs/{org}/properties/values')); assertType('', $client->call('PATCH /orgs/{org}/properties/values')); diff --git a/etc/specs/GitHub/current.spec.yaml b/etc/specs/GitHub/current.spec.yaml index eb3988c6d1d..1f9520a634e 100644 --- a/etc/specs/GitHub/current.spec.yaml +++ b/etc/specs/GitHub/current.spec.yaml @@ -67565,6 +67565,14 @@ components: format: date-time description: Timestamp of when the assignee's GitHub Copilot access was last updated, in ISO 8601 format. + plan_type: + type: string + description: The Copilot plan of the organization, or the parent enterprise, + when applicable. + enum: + - business + - enterprise + - unknown required: - assignee - created_at @@ -72210,6 +72218,14 @@ components: - assign_selected - disabled - unconfigured + plan_type: + type: string + description: The Copilot plan of the organization, or the parent enterprise, + when applicable. + enum: + - business + - enterprise + - unknown required: - seat_breakdown - public_code_suggestions @@ -199336,6 +199352,7 @@ components: pending_cancellation_date: last_activity_at: '2021-10-14T00:53:32-06:00' last_activity_editor: vscode/1.77.3/copilot/1.86.82 + plan_type: business assignee: login: octocat id: 1 @@ -202921,6 +202938,7 @@ components: platform_chat: enabled cli: enabled public_code_suggestions: block + plan_type: business organization-dependabot-secret-paginated: value: total_count: 3 @@ -203432,6 +203450,7 @@ components: pending_cancellation_date: last_activity_at: '2021-10-14T00:53:32-06:00' last_activity_editor: vscode/1.77.3/copilot/1.86.82 + plan_type: business assignee: login: octocat id: 1