From f44d6138fb95c10651bc83d20d945c0d434602f1 Mon Sep 17 00:00:00 2001 From: WyriHaximus <147145+WyriHaximus@users.noreply.github.com> Date: Fri, 1 Nov 2024 17:09:17 +0000 Subject: [PATCH] [GitHub] Update to 1.1.4-f1a89aa5fb6ef3d7a6d77044c06b8756 from 1.1.4-5758ce6a93c789209abf3a01ab532091 Detected Schema changes: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ``` ├─┬Paths │ ├──[➖] path (10205:3)❌ │ ├──[➖] path (10053:3)❌ │ ├──[➖] path (10020:3)❌ │ ├──[➖] path (10237:3)❌ │ ├──[➖] path (10112:3)❌ │ ├──[➖] path (10082:3)❌ │ ├──[➖] path (10144:3)❌ │ ├──[➖] path (10174:3)❌ │ ├──[➖] path (9985:3)❌ │ ├─┬/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id} │ │ ├─┬GET │ │ │ └──[🔀] description (48006:20) │ │ └─┬DELETE │ │ └──[🔀] description (48038:20) │ ├─┬/users/{username}/packages │ │ └─┬GET │ │ └──[🔀] description (47801:20) │ ├─┬/orgs/{org}/hooks/{hook_id}/deliveries │ │ └─┬GET │ │ └──[➕] parameters (9868:15)❌ │ ├─┬/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore │ │ └─┬POST │ │ └──[🔀] description (12007:20) │ ├─┬/user/packages/{package_type}/{package_name}/restore │ │ └─┬POST │ │ └──[🔀] description (45860:20) │ ├─┬/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id} │ │ ├─┬GET │ │ │ └──[🔀] description (11941:20) │ │ └─┬DELETE │ │ └──[🔀] description (11973:20) │ ├─┬/user/packages/{package_type}/{package_name}/versions/{package_version_id} │ │ ├─┬GET │ │ │ └──[🔀] description (45951:20) │ │ └─┬DELETE │ │ └──[🔀] description (45982:20) │ ├─┬/orgs/{org}/packages │ │ └─┬GET │ │ └──[🔀] description (11712:20) │ ├─┬/orgs/{org}/packages/{package_type}/{package_name}/versions │ │ └─┬GET │ │ └──[🔀] description (11889:20) │ ├─┬/user/packages/{package_type}/{package_name} │ │ ├─┬GET │ │ │ └──[🔀] description (45800:20) │ │ └─┬DELETE │ │ └──[🔀] description (45830:20) │ ├─┬/orgs/{org}/personal-access-token-requests │ │ └─┬GET │ │ └─┬Responses │ │ └─┬200 │ │ └─┬application/json │ │ └─┬default │ │ └──[🔀] value (206120:7) │ ├─┬/orgs/{org}/personal-access-tokens │ │ └─┬GET │ │ └─┬Responses │ │ └─┬200 │ │ └─┬application/json │ │ └─┬default │ │ └──[🔀] value (206154:7) │ ├─┬/user/packages │ │ └─┬GET │ │ └──[🔀] description (45747:20) │ ├─┬/users/{username}/packages/{package_type}/{package_name}/restore │ │ └─┬POST │ │ └──[🔀] description (47923:20) │ ├─┬/users/{username}/packages/{package_type}/{package_name}/versions │ │ └─┬GET │ │ └──[🔀] description (47966:20) │ ├─┬/app/hook/deliveries │ │ └─┬GET │ │ └──[➕] parameters (508:15)❌ │ ├─┬/repos/{owner}/{repo}/hooks/{hook_id}/deliveries │ │ └─┬GET │ │ └──[➕] parameters (30830:15)❌ │ ├─┬/orgs/{org}/packages/{package_type}/{package_name}/restore │ │ └─┬POST │ │ └──[🔀] description (11846:20) │ ├─┬/user/packages/{package_type}/{package_name}/versions/{package_version_id}/restore │ │ └─┬POST │ │ └──[🔀] description (46015:20) │ ├─┬/orgs/{org}/packages/{package_type}/{package_name} │ │ ├─┬GET │ │ │ └──[🔀] description (11782:20) │ │ └─┬DELETE │ │ └──[🔀] description (11813:20) │ ├─┬/user/packages/{package_type}/{package_name}/versions │ │ └─┬GET │ │ └──[🔀] description (45900:20) │ ├─┬/users/{username}/packages/{package_type}/{package_name} │ │ ├─┬GET │ │ │ └──[🔀] description (47859:20) │ │ └─┬DELETE │ │ └──[🔀] description (47890:20) │ └─┬/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore │ └─┬POST │ └──[🔀] description (48072:20) └─┬Components ├──[➖] parameters (225782:7)❌ ├──[➖] parameters (225849:7)❌ ├──[➖] parameters (225809:7)❌ ├──[➖] parameters (225795:7)❌ ├──[➖] parameters (225833:7)❌ ├──[➖] parameters (225856:7)❌ ├──[➖] parameters (225816:7)❌ ├──[➖] parameters (225802:7)❌ ├──[➖] examples (205457:7)❌ ├──[➖] examples (205467:7)❌ ├──[➖] examples (205491:7)❌ ├──[➖] examples (205449:7)❌ ├──[➖] examples (205471:7)❌ ├──[➖] schemas (74238:7)❌ ├──[➖] schemas (74210:7)❌ ├──[➖] schemas (74291:7)❌ ├──[➖] schemas (74276:7)❌ ├──[➖] schemas (74262:7)❌ ├─┬organization-programmatic-access-grant │ ├──[➖] required (74997:9)❌ │ ├──[➖] properties (74969:9)❌ │ └─┬id │ └──[🔀] description (74541:24) ├─┬personal-access-token-request │ ├──[➖] required (96964:9)❌ │ └──[➖] properties (96933:9)❌ ├─┬organization-programmatic-access-grant-request │ ├──[➖] required (74921:9)❌ │ └──[➖] properties (74892:9)❌ └─┬check-suite └─┬id └──[➖] format (81351:19)❌ ``` | Document Element | Total Changes | Breaking Changes | |------------------|---------------|------------------| | paths | 38 | 12 | | components | 26 | 25 | Date: 11/01/24 | Commit: New: etc/specs/GitHub/previous.spec.yaml, Original: etc/specs/GitHub/current.spec.yaml - ❌ **BREAKING Changes**: _37_ out of _64_ - **Modifications**: _27_ - **Removals**: _34_ - **Additions**: _3_ - **Breaking Removals**: _34_ - **Breaking Additions**: _3_ ERROR: breaking changes discovered --- clients/GitHub/README.md | 372 ++++++++++- .../GitHub/etc/openapi-client-generator.state | 282 ++++++-- clients/GitHub/src/Client.php | 2 +- clients/GitHub/src/ClientInterface.php | 2 +- .../Orgs/Org/Insights/Api/SummaryStats.php | 248 +++++++ .../Api/SummaryStats/ActorType/ActorId.php | 248 +++++++ .../Api/SummaryStats/Users/UserId.php | 248 +++++++ .../WebHook/PersonalAccessTokenRequest.php | 14 + clients/GitHub/src/Internal/Hydrators.php | 92 +++ .../ApiInsights/GetRouteStatsByActor.php | 97 +++ .../GetRouteStatsByActorListing.php | 97 +++ .../Operation/ApiInsights/GetSubjectStats.php | 91 +++ .../ApiInsights/GetSubjectStatsListing.php | 91 +++ .../Operation/ApiInsights/GetSummaryStats.php | 65 ++ .../ApiInsights/GetSummaryStatsByActor.php | 71 ++ .../ApiInsights/GetSummaryStatsByUser.php | 68 ++ .../Operation/ApiInsights/GetTimeStats.php | 82 +++ .../ApiInsights/GetTimeStatsByActor.php | 88 +++ .../ApiInsights/GetTimeStatsByUser.php | 85 +++ .../Operation/ApiInsights/GetUserStats.php | 94 +++ .../ApiInsights/GetUserStatsListing.php | 94 +++ .../Operation/Apps/ListWebhookDeliveries.php | 4 +- .../Operation/Orgs/ListWebhookDeliveries.php | 4 +- .../Operation/Repos/ListWebhookDeliveries.php | 4 +- .../ApiInsights/GetRouteStatsByActor.php | 41 ++ .../GetRouteStatsByActorListing.php | 41 ++ .../Operator/ApiInsights/GetSubjectStats.php | 41 ++ .../ApiInsights/GetSubjectStatsListing.php | 41 ++ .../Operator/ApiInsights/GetSummaryStats.php | 40 ++ .../ApiInsights/GetSummaryStatsByActor.php | 40 ++ .../ApiInsights/GetSummaryStatsByUser.php | 40 ++ .../Operator/ApiInsights/GetTimeStats.php | 41 ++ .../ApiInsights/GetTimeStatsByActor.php | 41 ++ .../ApiInsights/GetTimeStatsByUser.php | 41 ++ .../Operator/ApiInsights/GetUserStats.php | 41 ++ .../ApiInsights/GetUserStatsListing.php | 41 ++ .../Operator/Apps/ListWebhookDeliveries.php | 6 +- .../CodeScanning/DeleteCodeqlDatabase.php | 1 + .../Operator/Orgs/ListWebhookDeliveries.php | 6 +- .../Operator/Repos/ListWebhookDeliveries.php | 6 +- clients/GitHub/src/Internal/Operators.php | 120 ++++ .../Internal/Router/Delete/CodeScanning.php | 1 + .../src/Internal/Router/Delete/Eight.php | 2 +- .../src/Internal/Router/Get/ApiInsights.php | 406 ++++++++++++ .../GitHub/src/Internal/Router/Get/Apps.php | 10 +- .../GitHub/src/Internal/Router/Get/Eight.php | 47 +- .../GitHub/src/Internal/Router/Get/Four.php | 2 +- .../GitHub/src/Internal/Router/Get/Orgs.php | 10 +- .../GitHub/src/Internal/Router/Get/Repos.php | 10 +- .../GitHub/src/Internal/Router/Get/Seven.php | 12 +- .../GitHub/src/Internal/Router/Get/Six.php | 21 +- .../src/Internal/Router/List/ApiInsights.php | 211 ++++++ .../GitHub/src/Internal/Router/List/Eight.php | 16 +- .../GitHub/src/Internal/Router/List/Seven.php | 14 +- .../GitHub/src/Internal/Router/List/Six.php | 12 +- clients/GitHub/src/Internal/Routers.php | 20 + clients/GitHub/src/Operation/ApiInsights.php | 85 +++ clients/GitHub/src/Operation/Apps.php | 6 +- clients/GitHub/src/Operation/CodeScanning.php | 1 + clients/GitHub/src/Operation/Orgs.php | 6 +- clients/GitHub/src/Operation/Repos.php | 6 +- clients/GitHub/src/Operations.php | 5 + clients/GitHub/src/OperationsInterface.php | 2 + .../src/PHPStan/ClientCallReturnTypes.php | 56 +- .../src/Schema/ApiInsightsRouteStats.php | 69 ++ .../src/Schema/ApiInsightsSubjectStats.php | 63 ++ .../src/Schema/ApiInsightsSummaryStats.php | 44 ++ .../src/Schema/ApiInsightsTimeStats.php | 40 ++ .../src/Schema/ApiInsightsUserStats.php | 81 +++ clients/GitHub/src/Schema/CheckSuite.php | 1 + .../Response/ApplicationJson/Ok.php | 1 + .../OrganizationProgrammaticAccessGrant.php | 14 +- ...nizationProgrammaticAccessGrantRequest.php | 10 +- .../src/Schema/PersonalAccessTokenRequest.php | 10 +- ...hookPersonalAccessTokenRequestApproved.php | 6 + ...ookPersonalAccessTokenRequestCancelled.php | 6 + ...bhookPersonalAccessTokenRequestCreated.php | 6 + ...ebhookPersonalAccessTokenRequestDenied.php | 6 + .../GetRouteStatsByActorListingTest.php | 12 + .../ApiInsights/GetRouteStatsByActorTest.php | 12 + .../GetSubjectStatsListingTest.php | 12 + .../ApiInsights/GetSubjectStatsTest.php | 12 + .../GetSummaryStatsByActorTest.php | 58 ++ .../ApiInsights/GetSummaryStatsByUserTest.php | 57 ++ .../ApiInsights/GetSummaryStatsTest.php | 56 ++ .../ApiInsights/GetTimeStatsByActorTest.php | 12 + .../ApiInsights/GetTimeStatsByUserTest.php | 12 + .../ApiInsights/GetTimeStatsTest.php | 12 + .../ApiInsights/GetUserStatsListingTest.php | 12 + .../ApiInsights/GetUserStatsTest.php | 12 + .../Apps/ListWebhookDeliveriesTest.php | 33 +- .../Orgs/ListWebhookDeliveriesTest.php | 45 +- .../Repos/ListWebhookDeliveriesTest.php | 51 +- .../tests/Types/ClientCallReturnTypes.php | 20 +- etc/specs/GitHub/current.spec.yaml | 625 ++++++++++++++++-- 95 files changed, 5301 insertions(+), 241 deletions(-) create mode 100644 clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats.php create mode 100644 clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/ActorType/ActorId.php create mode 100644 clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/Users/UserId.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActor.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActorListing.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStats.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStatsListing.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStats.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByActor.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByUser.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStats.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByActor.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByUser.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStats.php create mode 100644 clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStatsListing.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActor.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActorListing.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStats.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStatsListing.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStats.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByActor.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByUser.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStats.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByActor.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByUser.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStats.php create mode 100644 clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStatsListing.php create mode 100644 clients/GitHub/src/Internal/Router/Get/ApiInsights.php create mode 100644 clients/GitHub/src/Internal/Router/List/ApiInsights.php create mode 100644 clients/GitHub/src/Operation/ApiInsights.php create mode 100644 clients/GitHub/src/Schema/ApiInsightsRouteStats.php create mode 100644 clients/GitHub/src/Schema/ApiInsightsSubjectStats.php create mode 100644 clients/GitHub/src/Schema/ApiInsightsSummaryStats.php create mode 100644 clients/GitHub/src/Schema/ApiInsightsTimeStats.php create mode 100644 clients/GitHub/src/Schema/ApiInsightsUserStats.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetRouteStatsByActorListingTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetRouteStatsByActorTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetSubjectStatsListingTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetSubjectStatsTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsByActorTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsByUserTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetTimeStatsByActorTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetTimeStatsByUserTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetTimeStatsTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetUserStatsListingTest.php create mode 100644 clients/GitHub/tests/Internal/Operation/ApiInsights/GetUserStatsTest.php diff --git a/clients/GitHub/README.md b/clients/GitHub/README.md index 4095c96cae2..97e1e00d5ab 100644 --- a/clients/GitHub/README.md +++ b/clients/GitHub/README.md @@ -206,7 +206,6 @@ Using the `call` method: ```php $client->call('GET /app/hook/deliveries', [ 'cursor' => 'generated', - 'redelivery' => , 'per_page' => 8, ]); ``` @@ -214,7 +213,6 @@ $client->call('GET /app/hook/deliveries', [ Operations method: ```php $client->operations()->apps()->listWebhookDeliveries( cursor: 'generated', - redelivery: , per_page: 8, ); ``` @@ -5458,7 +5456,6 @@ $client->call('GET /orgs/{org}/hooks/{hook_id}/deliveries', [ 'org' => 'generated', 'hook_id' => 7, 'cursor' => 'generated', - 'redelivery' => , 'per_page' => 8, ]); ``` @@ -5468,7 +5465,6 @@ Operations method: $client->operations()->orgs()->listWebhookDeliveries( org: 'generated', hook_id: 7, cursor: 'generated', - redelivery: , per_page: 8, ); ``` @@ -5546,6 +5542,372 @@ $client->operations()->orgs()->pingWebhook( org: 'generated', You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/webhooks#ping-an-organization-webhook). +### api-insights/get-route-stats-by-actor + +Get route stats by actor + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}', [ + 'org' => 'generated', + 'actor_type' => 'generated', + 'actor_id' => 8, + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'sort' => , + 'page' => 1, + 'per_page' => 8, + 'direction' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getRouteStatsByActor( org: 'generated', + actor_type: 'generated', + actor_id: 8, + min_timestamp: 'generated', + max_timestamp: 'generated', + sort: , + page: 1, + per_page: 8, + direction: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-route-stats-by-actor). + + +### api-insights/get-route-stats-by-actor + +Get route stats by actor + +Using the `call` method: +```php +$client->call('LIST /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}', [ + 'org' => 'generated', + 'actor_type' => 'generated', + 'actor_id' => 8, + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'sort' => , + 'page' => 1, + 'per_page' => 8, + 'direction' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getRouteStatsByActorListing( org: 'generated', + actor_type: 'generated', + actor_id: 8, + min_timestamp: 'generated', + max_timestamp: 'generated', + sort: , + page: 1, + per_page: 8, + direction: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-route-stats-by-actor). + + +### api-insights/get-subject-stats + +Get subject stats + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/subject-stats', [ + 'org' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'sort' => , + 'page' => 1, + 'per_page' => 8, + 'direction' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getSubjectStats( org: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', + sort: , + page: 1, + per_page: 8, + direction: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-subject-stats). + + +### api-insights/get-subject-stats + +Get subject stats + +Using the `call` method: +```php +$client->call('LIST /orgs/{org}/insights/api/subject-stats', [ + 'org' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'sort' => , + 'page' => 1, + 'per_page' => 8, + 'direction' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getSubjectStatsListing( org: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', + sort: , + page: 1, + per_page: 8, + direction: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-subject-stats). + + +### api-insights/get-summary-stats + +Get summary stats + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/summary-stats', [ + 'org' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getSummaryStats( org: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-summary-stats). + + +### api-insights/get-summary-stats-by-user + +Get summary stats by user + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/summary-stats/users/{user_id}', [ + 'org' => 'generated', + 'user_id' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getSummaryStatsByUser( org: 'generated', + user_id: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-summary-stats-by-user). + + +### api-insights/get-summary-stats-by-actor + +Get summary stats by actor + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/summary-stats/{actor_type}/{actor_id}', [ + 'org' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'actor_type' => 'generated', + 'actor_id' => 8, +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getSummaryStatsByActor( org: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', + actor_type: 'generated', + actor_id: 8, +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-summary-stats-by-actor). + + +### api-insights/get-time-stats + +Get time stats + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/time-stats', [ + 'org' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'timestamp_increment' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getTimeStats( org: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', + timestamp_increment: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-time-stats). + + +### api-insights/get-time-stats-by-user + +Get time stats by user + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/time-stats/users/{user_id}', [ + 'org' => 'generated', + 'user_id' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'timestamp_increment' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getTimeStatsByUser( org: 'generated', + user_id: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', + timestamp_increment: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-time-stats-by-user). + + +### api-insights/get-time-stats-by-actor + +Get time stats by actor + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/time-stats/{actor_type}/{actor_id}', [ + 'org' => 'generated', + 'actor_type' => 'generated', + 'actor_id' => 8, + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'timestamp_increment' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getTimeStatsByActor( org: 'generated', + actor_type: 'generated', + actor_id: 8, + min_timestamp: 'generated', + max_timestamp: 'generated', + timestamp_increment: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-time-stats-by-actor). + + +### api-insights/get-user-stats + +Get user stats + +Using the `call` method: +```php +$client->call('GET /orgs/{org}/insights/api/user-stats/{user_id}', [ + 'org' => 'generated', + 'user_id' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'sort' => , + 'page' => 1, + 'per_page' => 8, + 'direction' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getUserStats( org: 'generated', + user_id: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', + sort: , + page: 1, + per_page: 8, + direction: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-user-stats). + + +### api-insights/get-user-stats + +Get user stats + +Using the `call` method: +```php +$client->call('LIST /orgs/{org}/insights/api/user-stats/{user_id}', [ + 'org' => 'generated', + 'user_id' => 'generated', + 'min_timestamp' => 'generated', + 'max_timestamp' => 'generated', + 'sort' => , + 'page' => 1, + 'per_page' => 8, + 'direction' => 'generated', +]); +``` + +Operations method: +```php +$client->operations()->apiInsights()->getUserStatsListing( org: 'generated', + user_id: 'generated', + min_timestamp: 'generated', + max_timestamp: 'generated', + sort: , + page: 1, + per_page: 8, + direction: 'generated', +); +``` + +You can find more about this operation over at the [API method documentation](https://docs.github.com/rest/orgs/api-insights#get-user-stats). + + ### apps/get-org-installation Get an organization installation for the authenticated app @@ -17268,7 +17630,6 @@ $client->call('GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries', [ 'repo' => 'generated', 'hook_id' => 7, 'cursor' => 'generated', - 'redelivery' => , 'per_page' => 8, ]); ``` @@ -17279,7 +17640,6 @@ $client->operations()->repos()->listWebhookDeliveries( owner: 'generated' repo: 'generated', hook_id: 7, cursor: 'generated', - redelivery: , per_page: 8, ); ``` diff --git a/clients/GitHub/etc/openapi-client-generator.state b/clients/GitHub/etc/openapi-client-generator.state index b5e649bd512..abcb0f08584 100644 --- a/clients/GitHub/etc/openapi-client-generator.state +++ b/clients/GitHub/etc/openapi-client-generator.state @@ -1,5 +1,5 @@ { - "specHash": "5758ce6a93c789209abf3a01ab532091", + "specHash": "f1a89aa5fb6ef3d7a6d77044c06b8756", "generatedFiles": { "files": [ { @@ -280,11 +280,11 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/OrganizationProgrammaticAccessGrantRequest.php", - "hash": "750b71ea37b65c28c644c1dbf6fec80e" + "hash": "f699421bbe6ed43b52f1aed48eb4a7db" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/OrganizationProgrammaticAccessGrant.php", - "hash": "061926a9b218db1c28ff5e94055ca0ff" + "hash": "5ee3b08d4217bdacd831132c18527a76" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/OrganizationFull.php", @@ -836,7 +836,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/CheckSuite.php", - "hash": "4404a21ade5200b01d2b2ceeeef8db5f" + "hash": "b4978ef4bfc06cf01d25c8294ed030ad" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/CheckSuitePreference.php", @@ -1552,7 +1552,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/PersonalAccessTokenRequest.php", - "hash": "a0d756cb049c33109796f4a99c2c1a97" + "hash": "6723541927eb1437a1299399ff48cf2a" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/ProjectsV2.php", @@ -2024,19 +2024,19 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/WebhookPersonalAccessTokenRequestApproved.php", - "hash": "72a242435efe15696f3628943eb4ded6" + "hash": "830bb619332bcdfa426ad63f3f993347" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/WebhookPersonalAccessTokenRequestCancelled.php", - "hash": "0ada6be43616e048db0818c52e0857ca" + "hash": "c3d1fcef107dae18fa1adfd9a3ae5d12" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/WebhookPersonalAccessTokenRequestCreated.php", - "hash": "8bbca224408669975aa7e75080cd8a7e" + "hash": "8a5852abb023253d53099ddb0b2bd461" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/WebhookPersonalAccessTokenRequestDenied.php", - "hash": "877f9e8b08cba53f79869168fa8f97db" + "hash": "324bbba39aaf8b3efa584da036b1a301" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/WebhookPing.php", @@ -4960,7 +4960,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/Operations\/Checks\/ListSuitesForRef\/Response\/ApplicationJson\/Ok.php", - "hash": "a0ae79e5dbc141fd80c082d6193e0ee4" + "hash": "1594e1f3e1baf91efddcb033a04a11ba" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/Operations\/Repos\/GetContent\/Response\/ApplicationJson\/Ok.php", @@ -5500,15 +5500,15 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/ClientInterface.php", - "hash": "9a3c58462e80584fb8c6c5c72589817e" + "hash": "55bcc8c3f7087f80eb8285909a21150d" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Client.php", - "hash": "c78f8c6f8fa273c6432018dd0e5d7144" + "hash": "df2f484d2451a6017641293a187f1987" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/OperationsInterface.php", - "hash": "a51adebe9bb8532c5235f7b00a384c9d" + "hash": "3885fcb17667d023ee48c76fa85cfc91" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Meta.php", @@ -5516,7 +5516,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Apps.php", - "hash": "a9c167fe8affa0c9cecfe9755e253968" + "hash": "dd485689128bff8ec0a7f8982a41dd10" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/CodesOfConduct.php", @@ -5560,7 +5560,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Orgs.php", - "hash": "5779931bdcabc12f26dbc4d46b041ffe" + "hash": "5d374f0be56b72fb33b8aa678182b9ca" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Actions.php", @@ -5572,7 +5572,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/CodeScanning.php", - "hash": "b44a19071df22912d5b1612756134a44" + "hash": "f9715ddc7681e31dc8bef4da37fc1618" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Codespaces.php", @@ -5596,7 +5596,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Repos.php", - "hash": "413ffa311ea39a8cf15f4ed203f5211e" + "hash": "0aef6a4eccc9f76a73c638b2fd7e1e48" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Billing.php", @@ -5644,7 +5644,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operations.php", - "hash": "32f625a6ae248df8635163087bb17bfb" + "hash": "8fb76817c6551d0b9aa65fad26aedd0b" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/WebHooks.php", @@ -11632,7 +11632,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/Copilot.php", - "hash": "6688825af95a583a9a52e8a4d4cd4366" + "hash": "2e99352e83ca2b3425b47260f61aacf4" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/CheckAutomatedSecurityFixes.php", @@ -12104,15 +12104,15 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/Apps\/ListWebhookDeliveries.php", - "hash": "a053abfdc725412fd83b0e1f17a615d2" + "hash": "35500054776dafe75bb6058f40e4c087" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/Apps\/ListWebhookDeliveries.php", - "hash": "36a557aca6b7a917cbcbd17097e19f92" + "hash": "165bd5253ffd304c266367d671f2aa1a" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/Apps\/ListWebhookDeliveriesTest.php", - "hash": "ace0c02eef46f2109c537842961aaa18" + "hash": "8f09d78c5f5cf008e14f180b24b71158" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/Apps\/GetWebhookDelivery.php", @@ -14164,15 +14164,15 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/Orgs\/ListWebhookDeliveries.php", - "hash": "1c60afb7a40b0be2a7dd7a67dc1a68cb" + "hash": "14cf535082aa5c4358b68ae19e52da5a" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/Orgs\/ListWebhookDeliveries.php", - "hash": "9c252f65ec1bb76b251263f3d9ad67a8" + "hash": "382d9831dc2a5b3ba253d35ac2c865bf" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/Orgs\/ListWebhookDeliveriesTest.php", - "hash": "e49feeb39fd4a1c2a7efd1cde1339217" + "hash": "fb152a3c4c8d2eff2b05df8df64a22b9" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/Orgs\/GetWebhookDelivery.php", @@ -19012,15 +19012,15 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/Repos\/ListWebhookDeliveries.php", - "hash": "9cd1226ed48d5c325e447d9cbebeb766" + "hash": "d682cfdac5479a7ace784111711ceaed" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/Repos\/ListWebhookDeliveries.php", - "hash": "673778346778c58f23a834b2c86987b4" + "hash": "1f4d28f6fbc2ccec69b88f9b5f18bcfa" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/Repos\/ListWebhookDeliveriesTest.php", - "hash": "d96182ffc55b577d0dc688022765b974" + "hash": "08e85a9c699c983957dab5bc70dea6c2" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/Repos\/GetWebhookDelivery.php", @@ -24344,7 +24344,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Apps.php", - "hash": "972f88d252a8b582fcd02a974f971797" + "hash": "1d337c4237c48432ebbcba0c595fc24f" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/CodesOfConduct.php", @@ -24372,7 +24372,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Orgs.php", - "hash": "7aa1e49892497be27649dd82f16073ed" + "hash": "78b8a36998d1ce19e62b3390208baf03" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/RateLimit.php", @@ -24380,7 +24380,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Repos.php", - "hash": "6d2836d0de401a5cf89f3a0cc8ce5f98" + "hash": "9699969ac16cddac9d962470e5d167a4" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Users.php", @@ -24752,7 +24752,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/CodeScanning.php", - "hash": "84753ee31cc8bb9c8a149af182252cde" + "hash": "839a445e27296c454b92822433e2fbc1" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/Dependabot.php", @@ -24868,7 +24868,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Four.php", - "hash": "f248e13197b434832a0cbb6e3c9f1df4" + "hash": "3cd759ecadd9f1ef98cbdecf23f1ddd9" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Five.php", @@ -24876,15 +24876,15 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Six.php", - "hash": "b53d08b40a82186d3b569bde679af197" + "hash": "6ed1ecb55f4ae8cf04acc1c475c90200" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Seven.php", - "hash": "cdab06537a7f98fdf3c5ed86ada2f5f4" + "hash": "a14526043881620651ac452b3d5b34ef" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Eight.php", - "hash": "59c87acfb9e14c210b4c997bdde01a04" + "hash": "37094f76fdeaa04646bab6135a8f7bdb" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/Nine.php", @@ -24980,15 +24980,15 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/List\/Six.php", - "hash": "308c392e37c1750ea31302f83f39951f" + "hash": "9812269e81564353be3fc1d6da6f2fba" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/List\/Seven.php", - "hash": "d2b285c7b7a3494366fd113b6d5c5ac5" + "hash": "67751622c45a52cdc05fc38bc3fbb6fd" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/List\/Eight.php", - "hash": "23bdb9499299a0f47afc0c009e703d61" + "hash": "50b0aae5cf5d664d36f0080f508b4ac2" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/List\/Ten.php", @@ -25020,7 +25020,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/Eight.php", - "hash": "8a56724d85ab9ee985cdfd8c1f36c8b7" + "hash": "bdfff380f57481320d2a919737232069" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Delete\/Nine.php", @@ -25076,11 +25076,11 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Routers.php", - "hash": "6b62a7fa70f4d0b6d7c4ffa38c3fe73e" + "hash": "235ec7e7f4c1d476f09a71d137c97e09" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operators.php", - "hash": "0d4ee71e090bd30719d02f88808fff0d" + "hash": "b542a26bbdc98d29dadf0efc9c076d4a" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Root.php", @@ -27072,7 +27072,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrators.php", - "hash": "153e70befe62b6935d238622606cbced" + "hash": "647c407289259b5ffd10f1a5496c7e19" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/OrganizationSimpleWebhooks.php", @@ -27656,11 +27656,11 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/PHPStan\/ClientCallReturnTypes.php", - "hash": "52f53add13f4dd9b4a254971b986fd4a" + "hash": "98fc6c50cc51f6f7c274b33dc27f8bd0" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Types\/ClientCallReturnTypes.php", - "hash": "fd59bd2d3fcf851e7f60f4dd482837d1" + "hash": "91968b37bd6f4b77283d4262ef47fd56" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/..\/etc\/phpstan-extension.neon", @@ -28100,7 +28100,7 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/WebHook\/PersonalAccessTokenRequest.php", - "hash": "c1070bc3088a62740e1883a7ae6bc300" + "hash": "11605f2d4df5fab7def2c45abb7b9236" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/WebHook\/Ping.php", @@ -30820,11 +30820,199 @@ }, { "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/CodeScanning\/DeleteCodeqlDatabase.php", - "hash": "df190827fcd4219473ecf7999d93d76e" + "hash": "d998c40c2028672c9951f63fab1e0338" }, { "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/CodeScanning\/DeleteCodeqlDatabaseTest.php", "hash": "6f499eeba97d368253c2b5eb406630fa" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetRouteStatsByActor.php", + "hash": "b6749e4e332f0ae39e0bc8acb19cc594" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetRouteStatsByActor.php", + "hash": "d4c268f744b5ae9132327889ee93da57" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetRouteStatsByActorTest.php", + "hash": "5cb069ac8bdb0ba1b5f93fa232ccb84f" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetRouteStatsByActorListing.php", + "hash": "8d70c96384e2256609704c58915f38b8" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetRouteStatsByActorListing.php", + "hash": "81db61911d3da3073f923d5b0a8f01b0" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetRouteStatsByActorListingTest.php", + "hash": "018245411c06c1c4e2bcacc839855336" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetSubjectStats.php", + "hash": "3bb25c5f478e272f3624786904489370" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetSubjectStats.php", + "hash": "bb856ed9f9548dd1b047ed3366411ac3" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetSubjectStatsTest.php", + "hash": "007670b14ca605d850664159628f54e2" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetSubjectStatsListing.php", + "hash": "c245170bf28b825df98ebb4e05c4e077" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetSubjectStatsListing.php", + "hash": "4ff547c393a644a463ff6c00d034a23f" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetSubjectStatsListingTest.php", + "hash": "a9e82d88448c41d5f6c8e7adcc2f3d4a" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetSummaryStats.php", + "hash": "c7ff531f6f644ed2fcb43985c4112cc3" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetSummaryStats.php", + "hash": "52f2accff993f35ee26675d0a80f2f92" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetSummaryStatsTest.php", + "hash": "8f2812d6cda8be95aec444e20a4cde8d" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetSummaryStatsByUser.php", + "hash": "0dcfeaed97ccf1b2addb343c93ddf8ec" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetSummaryStatsByUser.php", + "hash": "d297ee62008f3108fd68b680a812ca5c" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetSummaryStatsByUserTest.php", + "hash": "157d93f998e6af9a06a08e8f871585b6" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetSummaryStatsByActor.php", + "hash": "d29380b566ae009b450ce21bf34b2e4a" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetSummaryStatsByActor.php", + "hash": "ba0ad561745834d9a78cedbc87c730ea" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetSummaryStatsByActorTest.php", + "hash": "3eef8248b4a00e3dbe9dec07aba90771" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetTimeStats.php", + "hash": "08917990450c1fc21e0a88d6f526370c" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetTimeStats.php", + "hash": "de7c1babf39d22d3fd4f1555905fc960" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetTimeStatsTest.php", + "hash": "c3268638a829eee0746911a3292feb44" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetTimeStatsByUser.php", + "hash": "2fbd03b6695c712c3a386fd9284e8e58" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetTimeStatsByUser.php", + "hash": "8045d95d4024779268593210dcc838d7" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetTimeStatsByUserTest.php", + "hash": "e86bf80920be800bd5e7c4b2586b22be" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetTimeStatsByActor.php", + "hash": "117497c2982a36f2268915156e220652" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetTimeStatsByActor.php", + "hash": "70377d40f16d66dd091b93395cb310a6" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetTimeStatsByActorTest.php", + "hash": "bfb9b988cb2435d78d07101187acb8a3" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetUserStats.php", + "hash": "f9fedf2d41ba73c0556f86ad084c1ca0" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetUserStats.php", + "hash": "133fcd00ebbe58d2379338f1e1bf2f6f" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetUserStatsTest.php", + "hash": "167d31aafd9413980cee41c31153b282" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operation\/ApiInsights\/GetUserStatsListing.php", + "hash": "36d2dba9115bf3d09b06f6de3b185571" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Operator\/ApiInsights\/GetUserStatsListing.php", + "hash": "bc3094654aa3f14ef788e6253d0172e6" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/tests\/\/Internal\/Operation\/ApiInsights\/GetUserStatsListingTest.php", + "hash": "2f4b6c19190a4fd7c7797e3935c3f65c" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/ApiInsightsRouteStats.php", + "hash": "94e9e07c27798cf8fd30ddde7294e605" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/ApiInsightsSubjectStats.php", + "hash": "976b3e85f11035e8f4a653e0797fda77" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/ApiInsightsSummaryStats.php", + "hash": "2699b5f8039cf389e481457f52d1df96" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/ApiInsightsTimeStats.php", + "hash": "06a3d2dee3425ef5b28faa4c75c26a65" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Schema\/ApiInsightsUserStats.php", + "hash": "48868fd16c04c0e5b9678c0cc63d14f1" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/Get\/ApiInsights.php", + "hash": "1fca596246826889b43466dfaa65ca5d" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Router\/List\/ApiInsights.php", + "hash": "133cab72347c3bcdd48daba79337dde6" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Operation\/ApiInsights.php", + "hash": "abf376a1022c40e61b1a4156232f7680" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Orgs\/Org\/Insights\/Api\/SummaryStats.php", + "hash": "da59df444fab5c8aa9c41d4f35a1e430" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Orgs\/Org\/Insights\/Api\/SummaryStats\/Users\/UserId.php", + "hash": "c13a542b389d63b3d51d0061bce0199d" + }, + { + "name": ".\/clients\/GitHub\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Orgs\/Org\/Insights\/Api\/SummaryStats\/ActorType\/ActorId.php", + "hash": "a93ba1f6eb83fc9f8c318615c49ba1d6" } ] }, diff --git a/clients/GitHub/src/Client.php b/clients/GitHub/src/Client.php index 9011d92036f..821b417b181 100644 --- a/clients/GitHub/src/Client.php +++ b/clients/GitHub/src/Client.php @@ -27,7 +27,7 @@ public function __construct(AuthenticationInterface $authentication, Browser $br } // phpcs:disable - public function call(string $call, array $params = []): \ApiClients\Client\GitHub\Schema\Root|iterable|\ApiClients\Client\GitHub\Schema\GlobalAdvisory|\ApiClients\Client\GitHub\Schema\Integration|\ApiClients\Client\GitHub\Schema\WebhookConfig|\ApiClients\Client\GitHub\Schema\HookDelivery|\ApiClients\Client\GitHub\Schema\Operations\Apps\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Tools\OpenApiClient\Utils\Response\WithoutBody|\ApiClients\Client\GitHub\Schema\Installation|\ApiClients\Client\GitHub\Schema\InstallationToken|\ApiClients\Client\GitHub\Schema\Authorization|\ApiClients\Client\GitHub\Schema\ClassroomAssignment|\ApiClients\Client\GitHub\Schema\Classroom|\ApiClients\Client\GitHub\Schema\CodeOfConduct|\ApiClients\Client\GitHub\Schema\Operations\Emojis\Get\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeatsForEnterprise\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Feed|\ApiClients\Client\GitHub\Schema\GistSimple|\ApiClients\Client\GitHub\Schema\GistComment|\ApiClients\Client\GitHub\Schema\BaseGist|\ApiClients\Client\GitHub\Schema\GitignoreTemplate|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListReposAccessibleToInstallation\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\License|string|\ApiClients\Client\GitHub\Schema\MarketplacePurchase|\ApiClients\Client\GitHub\Schema\ApiOverview|\ApiClients\Client\GitHub\Schema\BasicError|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Thread|\ApiClients\Client\GitHub\Schema\ThreadSubscription|\Psr\Http\Message\ResponseInterface|\ApiClients\Client\GitHub\Schema\OrganizationFull|\ApiClients\Client\GitHub\Schema\Operations\Orgs\Delete\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageOrgEnterprise|\ApiClients\Client\GitHub\Schema\Operations\Actions\GetActionsCacheUsageByRepoForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OidcCustomSub|\ApiClients\Client\GitHub\Schema\EmptyObject|\ApiClients\Client\GitHub\Schema\ActionsOrganizationPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedRepositoriesEnabledGithubActionsOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\SelectedActions|\ApiClients\Client\GitHub\Schema\ActionsGetDefaultWorkflowPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnerGroupsForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RunnerGroupsOrg|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoAccessToSelfHostedRunnerGroupInOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersInGroupForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\GenerateRunnerJitconfigForOrg\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\AuthenticationToken|\ApiClients\Client\GitHub\Schema\Runner|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListLabelsForSelfHostedRunnerForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgVariable\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeSecurityConfiguration|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\AttachConfiguration\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\SetConfigurationAsDefault\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesOrgSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CopilotOrganizationDetails|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeats\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForTeams\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForTeams\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForUsers\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForUsers\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationDependabotSecret|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\OrgHook|\ApiClients\Client\GitHub\Schema\Operations\Orgs\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAppInstallations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\InteractionLimitResponse|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForOrg\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\OrganizationInvitation|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\GetCodespacesForUserInOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteFromOrganization\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Codespace|\ApiClients\Client\GitHub\Schema\CopilotSeatDetails|\ApiClients\Client\GitHub\Schema\OrgMembership|\ApiClients\Client\GitHub\Schema\Migration|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListOrgRoles\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationRole|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ConvertMemberToOutsideCollaborator\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Package|\ApiClients\Client\GitHub\Schema\PackageVersion|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ReviewPatGrantRequestsInBulk\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\UpdatePatAccesses\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Project|\ApiClients\Client\GitHub\Schema\CustomProperty|\ApiClients\Client\GitHub\Schema\FullRepository|\ApiClients\Client\GitHub\Schema\RepositoryRuleset|\ApiClients\Client\GitHub\Schema\RuleSuite|\ApiClients\Client\GitHub\Schema\ActionsBillingUsage|\ApiClients\Client\GitHub\Schema\PackagesBillingUsage|\ApiClients\Client\GitHub\Schema\CombinedBillingUsage|\ApiClients\Client\GitHub\Schema\TeamFull|\ApiClients\Client\GitHub\Schema\TeamDiscussion|\ApiClients\Client\GitHub\Schema\TeamDiscussionComment|\ApiClients\Client\GitHub\Schema\Reaction|\ApiClients\Client\GitHub\Schema\TeamMembership|\ApiClients\Client\GitHub\Schema\TeamProject|\ApiClients\Client\GitHub\Schema\TeamRepository|\ApiClients\Client\GitHub\Schema\ProjectCard|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveCard\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectColumn|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveColumn\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectCollaboratorPermission|\ApiClients\Client\GitHub\Schema\RateLimitOverview|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListArtifactsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Artifact|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageByRepository|\ApiClients\Client\GitHub\Schema\ActionsCacheList|\ApiClients\Client\GitHub\Schema\Job|\ApiClients\Client\GitHub\Schema\OidcCustomSubRepo|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsRepositoryPermissions|\ApiClients\Client\GitHub\Schema\ActionsWorkflowAccessToRepository|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\WorkflowRun|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunArtifacts\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRunAttempt\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRun\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowRunUsage|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoWorkflows\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Workflow|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRuns\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowUsage|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateAttestation\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListAttestations\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Autolink|\ApiClients\Client\GitHub\Schema\CheckAutomatedSecurityFixes|\ApiClients\Client\GitHub\Schema\BranchWithProtection|\ApiClients\Client\GitHub\Schema\BranchProtection|\ApiClients\Client\GitHub\Schema\ProtectedBranch|\ApiClients\Client\GitHub\Schema\ProtectedBranchAdminEnforced|\ApiClients\Client\GitHub\Schema\ProtectedBranchPullRequestReview|\ApiClients\Client\GitHub\Schema\StatusCheckPolicy|\ApiClients\Client\GitHub\Schema\BranchRestrictionPolicy|\ApiClients\Client\GitHub\Schema\CheckRun|\ApiClients\Client\GitHub\Schema\CheckSuite|\ApiClients\Client\GitHub\Schema\CheckSuitePreference|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForSuite\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeScanningAlert|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysisDeletion|\ApiClients\Client\GitHub\Schema\CodeScanningCodeqlDatabase|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysisRepoTask|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetup|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetupUpdateResponse|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsReceipt|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsStatus|\ApiClients\Client\GitHub\Schema\CodeSecurityConfigurationForRepository|\ApiClients\Client\GitHub\Schema\CodeownersErrors|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInRepositoryForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\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|\ApiClients\Client\GitHub\Schema\CodespacesPermissionsCheckForDevcontainer|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RepoCodespacesSecret|\ApiClients\Client\GitHub\Schema\RepositoryInvitation|\ApiClients\Client\GitHub\Schema\RepositoryCollaboratorPermission|\ApiClients\Client\GitHub\Schema\CommitComment|\ApiClients\Client\GitHub\Schema\Commit|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForRef\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListSuitesForRef\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CombinedCommitStatus|\ApiClients\Client\GitHub\Schema\CommunityProfile|\ApiClients\Client\GitHub\Schema\CommitComparison|\ApiClients\Client\GitHub\Schema\ContentDirectory|\ApiClients\Client\GitHub\Schema\ContentFile|\ApiClients\Client\GitHub\Schema\ContentSymlink|\ApiClients\Client\GitHub\Schema\ContentSubmodule|\ApiClients\Client\GitHub\Schema\FileCommit|\ApiClients\Client\GitHub\Schema\DependabotAlert|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotSecret|\ApiClients\Client\GitHub\Schema\DependencyGraphSpdxSbom|\ApiClients\Client\GitHub\Schema\Operations\DependencyGraph\CreateRepositorySnapshot\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Deployment|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateDeployment\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\DeploymentStatus|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllEnvironments\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Environment|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListDeploymentBranchPolicies\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentBranchPolicy|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllDeploymentProtectionRules\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentProtectionRule|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListCustomDeploymentRuleIntegrations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ShortBlob|\ApiClients\Client\GitHub\Schema\Blob|\ApiClients\Client\GitHub\Schema\GitCommit|\ApiClients\Client\GitHub\Schema\GitRef|\ApiClients\Client\GitHub\Schema\GitTag|\ApiClients\Client\GitHub\Schema\GitTree|\ApiClients\Client\GitHub\Schema\Hook|\ApiClients\Client\GitHub\Schema\Operations\Repos\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Import|\ApiClients\Client\GitHub\Schema\PorterAuthor|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForRepo\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Issue|\ApiClients\Client\GitHub\Schema\IssueComment|\ApiClients\Client\GitHub\Schema\IssueEvent|\ApiClients\Client\GitHub\Schema\DeployKey|\ApiClients\Client\GitHub\Schema\Label|\ApiClients\Client\GitHub\Schema\Language|\ApiClients\Client\GitHub\Schema\LicenseContent|\ApiClients\Client\GitHub\Schema\MergedUpstream|\ApiClients\Client\GitHub\Schema\Milestone|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkRepoNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Page|\ApiClients\Client\GitHub\Schema\PageBuildStatus|\ApiClients\Client\GitHub\Schema\PageBuild|\ApiClients\Client\GitHub\Schema\PageDeployment|\ApiClients\Client\GitHub\Schema\PagesDeploymentStatus|\ApiClients\Client\GitHub\Schema\PagesHealthCheck|\ApiClients\Client\GitHub\Schema\Operations\Repos\CheckPrivateVulnerabilityReporting\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PullRequest|\ApiClients\Client\GitHub\Schema\PullRequestReviewComment|\ApiClients\Client\GitHub\Schema\PullRequestMergeResult|\ApiClients\Client\GitHub\Schema\PullRequestReviewRequest|\ApiClients\Client\GitHub\Schema\PullRequestSimple|\ApiClients\Client\GitHub\Schema\PullRequestReview|\ApiClients\Client\GitHub\Schema\Operations\Pulls\UpdateBranch\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Release|\ApiClients\Client\GitHub\Schema\ReleaseAsset|\ApiClients\Client\GitHub\Schema\ReleaseNotesContent|\ApiClients\Client\GitHub\Schema\SecretScanningAlert|\ApiClients\Client\GitHub\Schema\SecretScanningPushProtectionBypass|\ApiClients\Client\GitHub\Schema\RepositoryAdvisory|\ApiClients\Client\GitHub\Schema\Operations\SecurityAdvisories\CreateRepositoryAdvisoryCveRequest\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\SimpleUser|\ApiClients\Client\GitHub\Schema\Stargazer|\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|\ApiClients\Client\GitHub\Schema\ParticipationStats|\ApiClients\Client\GitHub\Schema\Status|\ApiClients\Client\GitHub\Schema\RepositorySubscription|\ApiClients\Client\GitHub\Schema\TagProtection|\ApiClients\Client\GitHub\Schema\Topic|\ApiClients\Client\GitHub\Schema\CloneTraffic|\ApiClients\Client\GitHub\Schema\ViewTraffic|\ApiClients\Client\GitHub\Schema\MinimalRepository|\ApiClients\Client\GitHub\Schema\Operations\Search\Code\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Commits\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\IssuesAndPullRequests\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Labels\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Repos\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Topics\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Users\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PrivateUser|\ApiClients\Client\GitHub\Schema\PublicUser|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSecretsForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesUserPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepositoriesForSecretForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteForAuthenticatedUser\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceExportDetails|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\CodespaceMachinesForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceWithFullRepository|\ApiClients\Client\GitHub\Schema\GpgKey|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationReposForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Key|\ApiClients\Client\GitHub\Schema\SshSigningKey|\ApiClients\Client\GitHub\Schema\Operations\Users\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Hovercard|\ApiClients\Client\GitHub\Schema\StarredRepository|\ApiClients\Client\GitHub\Schema\Repository + public function call(string $call, array $params = []): \ApiClients\Client\GitHub\Schema\Root|iterable|\ApiClients\Client\GitHub\Schema\GlobalAdvisory|\ApiClients\Client\GitHub\Schema\Integration|\ApiClients\Client\GitHub\Schema\WebhookConfig|\ApiClients\Client\GitHub\Schema\HookDelivery|\ApiClients\Client\GitHub\Schema\Operations\Apps\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Tools\OpenApiClient\Utils\Response\WithoutBody|\ApiClients\Client\GitHub\Schema\Installation|\ApiClients\Client\GitHub\Schema\InstallationToken|\ApiClients\Client\GitHub\Schema\Authorization|\ApiClients\Client\GitHub\Schema\ClassroomAssignment|\ApiClients\Client\GitHub\Schema\Classroom|\ApiClients\Client\GitHub\Schema\CodeOfConduct|\ApiClients\Client\GitHub\Schema\Operations\Emojis\Get\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeatsForEnterprise\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Feed|\ApiClients\Client\GitHub\Schema\GistSimple|\ApiClients\Client\GitHub\Schema\GistComment|\ApiClients\Client\GitHub\Schema\BaseGist|\ApiClients\Client\GitHub\Schema\GitignoreTemplate|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListReposAccessibleToInstallation\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\License|string|\ApiClients\Client\GitHub\Schema\MarketplacePurchase|\ApiClients\Client\GitHub\Schema\ApiOverview|\ApiClients\Client\GitHub\Schema\BasicError|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Thread|\ApiClients\Client\GitHub\Schema\ThreadSubscription|\Psr\Http\Message\ResponseInterface|\ApiClients\Client\GitHub\Schema\OrganizationFull|\ApiClients\Client\GitHub\Schema\Operations\Orgs\Delete\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageOrgEnterprise|\ApiClients\Client\GitHub\Schema\Operations\Actions\GetActionsCacheUsageByRepoForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OidcCustomSub|\ApiClients\Client\GitHub\Schema\EmptyObject|\ApiClients\Client\GitHub\Schema\ActionsOrganizationPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedRepositoriesEnabledGithubActionsOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\SelectedActions|\ApiClients\Client\GitHub\Schema\ActionsGetDefaultWorkflowPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnerGroupsForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RunnerGroupsOrg|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoAccessToSelfHostedRunnerGroupInOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersInGroupForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\GenerateRunnerJitconfigForOrg\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\AuthenticationToken|\ApiClients\Client\GitHub\Schema\Runner|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListLabelsForSelfHostedRunnerForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgVariable\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeSecurityConfiguration|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\AttachConfiguration\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\SetConfigurationAsDefault\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesOrgSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CopilotOrganizationDetails|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeats\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForTeams\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForTeams\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForUsers\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForUsers\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationDependabotSecret|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\OrgHook|\ApiClients\Client\GitHub\Schema\Operations\Orgs\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAppInstallations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\InteractionLimitResponse|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForOrg\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\OrganizationInvitation|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\GetCodespacesForUserInOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteFromOrganization\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Codespace|\ApiClients\Client\GitHub\Schema\CopilotSeatDetails|\ApiClients\Client\GitHub\Schema\OrgMembership|\ApiClients\Client\GitHub\Schema\Migration|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListOrgRoles\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationRole|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ConvertMemberToOutsideCollaborator\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Package|\ApiClients\Client\GitHub\Schema\PackageVersion|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ReviewPatGrantRequestsInBulk\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\UpdatePatAccesses\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Project|\ApiClients\Client\GitHub\Schema\CustomProperty|\ApiClients\Client\GitHub\Schema\FullRepository|\ApiClients\Client\GitHub\Schema\RepositoryRuleset|\ApiClients\Client\GitHub\Schema\RuleSuite|\ApiClients\Client\GitHub\Schema\ActionsBillingUsage|\ApiClients\Client\GitHub\Schema\PackagesBillingUsage|\ApiClients\Client\GitHub\Schema\CombinedBillingUsage|\ApiClients\Client\GitHub\Schema\TeamFull|\ApiClients\Client\GitHub\Schema\TeamDiscussion|\ApiClients\Client\GitHub\Schema\TeamDiscussionComment|\ApiClients\Client\GitHub\Schema\Reaction|\ApiClients\Client\GitHub\Schema\TeamMembership|\ApiClients\Client\GitHub\Schema\TeamProject|\ApiClients\Client\GitHub\Schema\TeamRepository|\ApiClients\Client\GitHub\Schema\ProjectCard|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveCard\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectColumn|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveColumn\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectCollaboratorPermission|\ApiClients\Client\GitHub\Schema\RateLimitOverview|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListArtifactsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Artifact|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageByRepository|\ApiClients\Client\GitHub\Schema\ActionsCacheList|\ApiClients\Client\GitHub\Schema\Job|\ApiClients\Client\GitHub\Schema\OidcCustomSubRepo|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsRepositoryPermissions|\ApiClients\Client\GitHub\Schema\ActionsWorkflowAccessToRepository|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\WorkflowRun|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunArtifacts\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRunAttempt\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRun\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowRunUsage|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoWorkflows\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Workflow|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRuns\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowUsage|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateAttestation\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListAttestations\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Autolink|\ApiClients\Client\GitHub\Schema\CheckAutomatedSecurityFixes|\ApiClients\Client\GitHub\Schema\BranchWithProtection|\ApiClients\Client\GitHub\Schema\BranchProtection|\ApiClients\Client\GitHub\Schema\ProtectedBranch|\ApiClients\Client\GitHub\Schema\ProtectedBranchAdminEnforced|\ApiClients\Client\GitHub\Schema\ProtectedBranchPullRequestReview|\ApiClients\Client\GitHub\Schema\StatusCheckPolicy|\ApiClients\Client\GitHub\Schema\BranchRestrictionPolicy|\ApiClients\Client\GitHub\Schema\CheckRun|\ApiClients\Client\GitHub\Schema\CheckSuite|\ApiClients\Client\GitHub\Schema\CheckSuitePreference|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForSuite\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeScanningAlert|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysisDeletion|\ApiClients\Client\GitHub\Schema\CodeScanningCodeqlDatabase|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysisRepoTask|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetup|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetupUpdateResponse|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsReceipt|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsStatus|\ApiClients\Client\GitHub\Schema\CodeSecurityConfigurationForRepository|\ApiClients\Client\GitHub\Schema\CodeownersErrors|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInRepositoryForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\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|\ApiClients\Client\GitHub\Schema\CodespacesPermissionsCheckForDevcontainer|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RepoCodespacesSecret|\ApiClients\Client\GitHub\Schema\RepositoryInvitation|\ApiClients\Client\GitHub\Schema\RepositoryCollaboratorPermission|\ApiClients\Client\GitHub\Schema\CommitComment|\ApiClients\Client\GitHub\Schema\Commit|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForRef\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListSuitesForRef\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CombinedCommitStatus|\ApiClients\Client\GitHub\Schema\CommunityProfile|\ApiClients\Client\GitHub\Schema\CommitComparison|\ApiClients\Client\GitHub\Schema\ContentDirectory|\ApiClients\Client\GitHub\Schema\ContentFile|\ApiClients\Client\GitHub\Schema\ContentSymlink|\ApiClients\Client\GitHub\Schema\ContentSubmodule|\ApiClients\Client\GitHub\Schema\FileCommit|\ApiClients\Client\GitHub\Schema\DependabotAlert|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotSecret|\ApiClients\Client\GitHub\Schema\DependencyGraphSpdxSbom|\ApiClients\Client\GitHub\Schema\Operations\DependencyGraph\CreateRepositorySnapshot\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Deployment|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateDeployment\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\DeploymentStatus|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllEnvironments\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Environment|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListDeploymentBranchPolicies\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentBranchPolicy|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllDeploymentProtectionRules\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentProtectionRule|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListCustomDeploymentRuleIntegrations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ShortBlob|\ApiClients\Client\GitHub\Schema\Blob|\ApiClients\Client\GitHub\Schema\GitCommit|\ApiClients\Client\GitHub\Schema\GitRef|\ApiClients\Client\GitHub\Schema\GitTag|\ApiClients\Client\GitHub\Schema\GitTree|\ApiClients\Client\GitHub\Schema\Hook|\ApiClients\Client\GitHub\Schema\Operations\Repos\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Import|\ApiClients\Client\GitHub\Schema\PorterAuthor|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForRepo\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Issue|\ApiClients\Client\GitHub\Schema\IssueComment|\ApiClients\Client\GitHub\Schema\IssueEvent|\ApiClients\Client\GitHub\Schema\DeployKey|\ApiClients\Client\GitHub\Schema\Label|\ApiClients\Client\GitHub\Schema\Language|\ApiClients\Client\GitHub\Schema\LicenseContent|\ApiClients\Client\GitHub\Schema\MergedUpstream|\ApiClients\Client\GitHub\Schema\Milestone|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkRepoNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Page|\ApiClients\Client\GitHub\Schema\PageBuildStatus|\ApiClients\Client\GitHub\Schema\PageBuild|\ApiClients\Client\GitHub\Schema\PageDeployment|\ApiClients\Client\GitHub\Schema\PagesDeploymentStatus|\ApiClients\Client\GitHub\Schema\PagesHealthCheck|\ApiClients\Client\GitHub\Schema\Operations\Repos\CheckPrivateVulnerabilityReporting\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PullRequest|\ApiClients\Client\GitHub\Schema\PullRequestReviewComment|\ApiClients\Client\GitHub\Schema\PullRequestMergeResult|\ApiClients\Client\GitHub\Schema\PullRequestReviewRequest|\ApiClients\Client\GitHub\Schema\PullRequestSimple|\ApiClients\Client\GitHub\Schema\PullRequestReview|\ApiClients\Client\GitHub\Schema\Operations\Pulls\UpdateBranch\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Release|\ApiClients\Client\GitHub\Schema\ReleaseAsset|\ApiClients\Client\GitHub\Schema\ReleaseNotesContent|\ApiClients\Client\GitHub\Schema\SecretScanningAlert|\ApiClients\Client\GitHub\Schema\SecretScanningPushProtectionBypass|\ApiClients\Client\GitHub\Schema\RepositoryAdvisory|\ApiClients\Client\GitHub\Schema\Operations\SecurityAdvisories\CreateRepositoryAdvisoryCveRequest\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\SimpleUser|\ApiClients\Client\GitHub\Schema\Stargazer|\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|\ApiClients\Client\GitHub\Schema\ParticipationStats|\ApiClients\Client\GitHub\Schema\Status|\ApiClients\Client\GitHub\Schema\RepositorySubscription|\ApiClients\Client\GitHub\Schema\TagProtection|\ApiClients\Client\GitHub\Schema\Topic|\ApiClients\Client\GitHub\Schema\CloneTraffic|\ApiClients\Client\GitHub\Schema\ViewTraffic|\ApiClients\Client\GitHub\Schema\MinimalRepository|\ApiClients\Client\GitHub\Schema\Operations\Search\Code\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Commits\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\IssuesAndPullRequests\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Labels\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Repos\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Topics\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Users\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PrivateUser|\ApiClients\Client\GitHub\Schema\PublicUser|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSecretsForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesUserPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepositoriesForSecretForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteForAuthenticatedUser\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceExportDetails|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\CodespaceMachinesForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceWithFullRepository|\ApiClients\Client\GitHub\Schema\GpgKey|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationReposForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Key|\ApiClients\Client\GitHub\Schema\SshSigningKey|\ApiClients\Client\GitHub\Schema\Operations\Users\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Hovercard|\ApiClients\Client\GitHub\Schema\StarredRepository|\ApiClients\Client\GitHub\Schema\Repository { [$method, $path] = explode(' ', $call); $pathChunks = explode('/', $path); diff --git a/clients/GitHub/src/ClientInterface.php b/clients/GitHub/src/ClientInterface.php index 2003a23f119..c58e8867e2d 100644 --- a/clients/GitHub/src/ClientInterface.php +++ b/clients/GitHub/src/ClientInterface.php @@ -7,7 +7,7 @@ interface ClientInterface { // phpcs:disable - public function call(string $call, array $params = []): \ApiClients\Client\GitHub\Schema\Root|iterable|\ApiClients\Client\GitHub\Schema\GlobalAdvisory|\ApiClients\Client\GitHub\Schema\Integration|\ApiClients\Client\GitHub\Schema\WebhookConfig|\ApiClients\Client\GitHub\Schema\HookDelivery|\ApiClients\Client\GitHub\Schema\Operations\Apps\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Tools\OpenApiClient\Utils\Response\WithoutBody|\ApiClients\Client\GitHub\Schema\Installation|\ApiClients\Client\GitHub\Schema\InstallationToken|\ApiClients\Client\GitHub\Schema\Authorization|\ApiClients\Client\GitHub\Schema\ClassroomAssignment|\ApiClients\Client\GitHub\Schema\Classroom|\ApiClients\Client\GitHub\Schema\CodeOfConduct|\ApiClients\Client\GitHub\Schema\Operations\Emojis\Get\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeatsForEnterprise\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Feed|\ApiClients\Client\GitHub\Schema\GistSimple|\ApiClients\Client\GitHub\Schema\GistComment|\ApiClients\Client\GitHub\Schema\BaseGist|\ApiClients\Client\GitHub\Schema\GitignoreTemplate|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListReposAccessibleToInstallation\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\License|string|\ApiClients\Client\GitHub\Schema\MarketplacePurchase|\ApiClients\Client\GitHub\Schema\ApiOverview|\ApiClients\Client\GitHub\Schema\BasicError|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Thread|\ApiClients\Client\GitHub\Schema\ThreadSubscription|\Psr\Http\Message\ResponseInterface|\ApiClients\Client\GitHub\Schema\OrganizationFull|\ApiClients\Client\GitHub\Schema\Operations\Orgs\Delete\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageOrgEnterprise|\ApiClients\Client\GitHub\Schema\Operations\Actions\GetActionsCacheUsageByRepoForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OidcCustomSub|\ApiClients\Client\GitHub\Schema\EmptyObject|\ApiClients\Client\GitHub\Schema\ActionsOrganizationPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedRepositoriesEnabledGithubActionsOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\SelectedActions|\ApiClients\Client\GitHub\Schema\ActionsGetDefaultWorkflowPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnerGroupsForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RunnerGroupsOrg|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoAccessToSelfHostedRunnerGroupInOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersInGroupForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\GenerateRunnerJitconfigForOrg\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\AuthenticationToken|\ApiClients\Client\GitHub\Schema\Runner|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListLabelsForSelfHostedRunnerForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgVariable\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeSecurityConfiguration|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\AttachConfiguration\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\SetConfigurationAsDefault\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesOrgSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CopilotOrganizationDetails|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeats\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForTeams\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForTeams\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForUsers\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForUsers\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationDependabotSecret|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\OrgHook|\ApiClients\Client\GitHub\Schema\Operations\Orgs\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAppInstallations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\InteractionLimitResponse|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForOrg\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\OrganizationInvitation|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\GetCodespacesForUserInOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteFromOrganization\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Codespace|\ApiClients\Client\GitHub\Schema\CopilotSeatDetails|\ApiClients\Client\GitHub\Schema\OrgMembership|\ApiClients\Client\GitHub\Schema\Migration|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListOrgRoles\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationRole|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ConvertMemberToOutsideCollaborator\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Package|\ApiClients\Client\GitHub\Schema\PackageVersion|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ReviewPatGrantRequestsInBulk\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\UpdatePatAccesses\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Project|\ApiClients\Client\GitHub\Schema\CustomProperty|\ApiClients\Client\GitHub\Schema\FullRepository|\ApiClients\Client\GitHub\Schema\RepositoryRuleset|\ApiClients\Client\GitHub\Schema\RuleSuite|\ApiClients\Client\GitHub\Schema\ActionsBillingUsage|\ApiClients\Client\GitHub\Schema\PackagesBillingUsage|\ApiClients\Client\GitHub\Schema\CombinedBillingUsage|\ApiClients\Client\GitHub\Schema\TeamFull|\ApiClients\Client\GitHub\Schema\TeamDiscussion|\ApiClients\Client\GitHub\Schema\TeamDiscussionComment|\ApiClients\Client\GitHub\Schema\Reaction|\ApiClients\Client\GitHub\Schema\TeamMembership|\ApiClients\Client\GitHub\Schema\TeamProject|\ApiClients\Client\GitHub\Schema\TeamRepository|\ApiClients\Client\GitHub\Schema\ProjectCard|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveCard\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectColumn|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveColumn\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectCollaboratorPermission|\ApiClients\Client\GitHub\Schema\RateLimitOverview|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListArtifactsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Artifact|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageByRepository|\ApiClients\Client\GitHub\Schema\ActionsCacheList|\ApiClients\Client\GitHub\Schema\Job|\ApiClients\Client\GitHub\Schema\OidcCustomSubRepo|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsRepositoryPermissions|\ApiClients\Client\GitHub\Schema\ActionsWorkflowAccessToRepository|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\WorkflowRun|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunArtifacts\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRunAttempt\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRun\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowRunUsage|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoWorkflows\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Workflow|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRuns\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowUsage|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateAttestation\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListAttestations\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Autolink|\ApiClients\Client\GitHub\Schema\CheckAutomatedSecurityFixes|\ApiClients\Client\GitHub\Schema\BranchWithProtection|\ApiClients\Client\GitHub\Schema\BranchProtection|\ApiClients\Client\GitHub\Schema\ProtectedBranch|\ApiClients\Client\GitHub\Schema\ProtectedBranchAdminEnforced|\ApiClients\Client\GitHub\Schema\ProtectedBranchPullRequestReview|\ApiClients\Client\GitHub\Schema\StatusCheckPolicy|\ApiClients\Client\GitHub\Schema\BranchRestrictionPolicy|\ApiClients\Client\GitHub\Schema\CheckRun|\ApiClients\Client\GitHub\Schema\CheckSuite|\ApiClients\Client\GitHub\Schema\CheckSuitePreference|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForSuite\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeScanningAlert|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysisDeletion|\ApiClients\Client\GitHub\Schema\CodeScanningCodeqlDatabase|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysisRepoTask|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetup|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetupUpdateResponse|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsReceipt|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsStatus|\ApiClients\Client\GitHub\Schema\CodeSecurityConfigurationForRepository|\ApiClients\Client\GitHub\Schema\CodeownersErrors|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInRepositoryForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\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|\ApiClients\Client\GitHub\Schema\CodespacesPermissionsCheckForDevcontainer|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RepoCodespacesSecret|\ApiClients\Client\GitHub\Schema\RepositoryInvitation|\ApiClients\Client\GitHub\Schema\RepositoryCollaboratorPermission|\ApiClients\Client\GitHub\Schema\CommitComment|\ApiClients\Client\GitHub\Schema\Commit|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForRef\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListSuitesForRef\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CombinedCommitStatus|\ApiClients\Client\GitHub\Schema\CommunityProfile|\ApiClients\Client\GitHub\Schema\CommitComparison|\ApiClients\Client\GitHub\Schema\ContentDirectory|\ApiClients\Client\GitHub\Schema\ContentFile|\ApiClients\Client\GitHub\Schema\ContentSymlink|\ApiClients\Client\GitHub\Schema\ContentSubmodule|\ApiClients\Client\GitHub\Schema\FileCommit|\ApiClients\Client\GitHub\Schema\DependabotAlert|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotSecret|\ApiClients\Client\GitHub\Schema\DependencyGraphSpdxSbom|\ApiClients\Client\GitHub\Schema\Operations\DependencyGraph\CreateRepositorySnapshot\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Deployment|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateDeployment\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\DeploymentStatus|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllEnvironments\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Environment|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListDeploymentBranchPolicies\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentBranchPolicy|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllDeploymentProtectionRules\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentProtectionRule|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListCustomDeploymentRuleIntegrations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ShortBlob|\ApiClients\Client\GitHub\Schema\Blob|\ApiClients\Client\GitHub\Schema\GitCommit|\ApiClients\Client\GitHub\Schema\GitRef|\ApiClients\Client\GitHub\Schema\GitTag|\ApiClients\Client\GitHub\Schema\GitTree|\ApiClients\Client\GitHub\Schema\Hook|\ApiClients\Client\GitHub\Schema\Operations\Repos\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Import|\ApiClients\Client\GitHub\Schema\PorterAuthor|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForRepo\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Issue|\ApiClients\Client\GitHub\Schema\IssueComment|\ApiClients\Client\GitHub\Schema\IssueEvent|\ApiClients\Client\GitHub\Schema\DeployKey|\ApiClients\Client\GitHub\Schema\Label|\ApiClients\Client\GitHub\Schema\Language|\ApiClients\Client\GitHub\Schema\LicenseContent|\ApiClients\Client\GitHub\Schema\MergedUpstream|\ApiClients\Client\GitHub\Schema\Milestone|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkRepoNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Page|\ApiClients\Client\GitHub\Schema\PageBuildStatus|\ApiClients\Client\GitHub\Schema\PageBuild|\ApiClients\Client\GitHub\Schema\PageDeployment|\ApiClients\Client\GitHub\Schema\PagesDeploymentStatus|\ApiClients\Client\GitHub\Schema\PagesHealthCheck|\ApiClients\Client\GitHub\Schema\Operations\Repos\CheckPrivateVulnerabilityReporting\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PullRequest|\ApiClients\Client\GitHub\Schema\PullRequestReviewComment|\ApiClients\Client\GitHub\Schema\PullRequestMergeResult|\ApiClients\Client\GitHub\Schema\PullRequestReviewRequest|\ApiClients\Client\GitHub\Schema\PullRequestSimple|\ApiClients\Client\GitHub\Schema\PullRequestReview|\ApiClients\Client\GitHub\Schema\Operations\Pulls\UpdateBranch\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Release|\ApiClients\Client\GitHub\Schema\ReleaseAsset|\ApiClients\Client\GitHub\Schema\ReleaseNotesContent|\ApiClients\Client\GitHub\Schema\SecretScanningAlert|\ApiClients\Client\GitHub\Schema\SecretScanningPushProtectionBypass|\ApiClients\Client\GitHub\Schema\RepositoryAdvisory|\ApiClients\Client\GitHub\Schema\Operations\SecurityAdvisories\CreateRepositoryAdvisoryCveRequest\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\SimpleUser|\ApiClients\Client\GitHub\Schema\Stargazer|\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|\ApiClients\Client\GitHub\Schema\ParticipationStats|\ApiClients\Client\GitHub\Schema\Status|\ApiClients\Client\GitHub\Schema\RepositorySubscription|\ApiClients\Client\GitHub\Schema\TagProtection|\ApiClients\Client\GitHub\Schema\Topic|\ApiClients\Client\GitHub\Schema\CloneTraffic|\ApiClients\Client\GitHub\Schema\ViewTraffic|\ApiClients\Client\GitHub\Schema\MinimalRepository|\ApiClients\Client\GitHub\Schema\Operations\Search\Code\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Commits\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\IssuesAndPullRequests\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Labels\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Repos\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Topics\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Users\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PrivateUser|\ApiClients\Client\GitHub\Schema\PublicUser|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSecretsForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesUserPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepositoriesForSecretForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteForAuthenticatedUser\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceExportDetails|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\CodespaceMachinesForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceWithFullRepository|\ApiClients\Client\GitHub\Schema\GpgKey|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationReposForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Key|\ApiClients\Client\GitHub\Schema\SshSigningKey|\ApiClients\Client\GitHub\Schema\Operations\Users\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Hovercard|\ApiClients\Client\GitHub\Schema\StarredRepository|\ApiClients\Client\GitHub\Schema\Repository; + public function call(string $call, array $params = []): \ApiClients\Client\GitHub\Schema\Root|iterable|\ApiClients\Client\GitHub\Schema\GlobalAdvisory|\ApiClients\Client\GitHub\Schema\Integration|\ApiClients\Client\GitHub\Schema\WebhookConfig|\ApiClients\Client\GitHub\Schema\HookDelivery|\ApiClients\Client\GitHub\Schema\Operations\Apps\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Tools\OpenApiClient\Utils\Response\WithoutBody|\ApiClients\Client\GitHub\Schema\Installation|\ApiClients\Client\GitHub\Schema\InstallationToken|\ApiClients\Client\GitHub\Schema\Authorization|\ApiClients\Client\GitHub\Schema\ClassroomAssignment|\ApiClients\Client\GitHub\Schema\Classroom|\ApiClients\Client\GitHub\Schema\CodeOfConduct|\ApiClients\Client\GitHub\Schema\Operations\Emojis\Get\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeatsForEnterprise\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Feed|\ApiClients\Client\GitHub\Schema\GistSimple|\ApiClients\Client\GitHub\Schema\GistComment|\ApiClients\Client\GitHub\Schema\BaseGist|\ApiClients\Client\GitHub\Schema\GitignoreTemplate|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListReposAccessibleToInstallation\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\License|string|\ApiClients\Client\GitHub\Schema\MarketplacePurchase|\ApiClients\Client\GitHub\Schema\ApiOverview|\ApiClients\Client\GitHub\Schema\BasicError|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Thread|\ApiClients\Client\GitHub\Schema\ThreadSubscription|\Psr\Http\Message\ResponseInterface|\ApiClients\Client\GitHub\Schema\OrganizationFull|\ApiClients\Client\GitHub\Schema\Operations\Orgs\Delete\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageOrgEnterprise|\ApiClients\Client\GitHub\Schema\Operations\Actions\GetActionsCacheUsageByRepoForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OidcCustomSub|\ApiClients\Client\GitHub\Schema\EmptyObject|\ApiClients\Client\GitHub\Schema\ActionsOrganizationPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedRepositoriesEnabledGithubActionsOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\SelectedActions|\ApiClients\Client\GitHub\Schema\ActionsGetDefaultWorkflowPermissions|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnerGroupsForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RunnerGroupsOrg|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoAccessToSelfHostedRunnerGroupInOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersInGroupForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\GenerateRunnerJitconfigForOrg\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\AuthenticationToken|\ApiClients\Client\GitHub\Schema\Runner|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListLabelsForSelfHostedRunnerForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListOrgVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgVariable\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeSecurityConfiguration|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\AttachConfiguration\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\CodeSecurity\SetConfigurationAsDefault\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInOrganization\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesOrgSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CopilotOrganizationDetails|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeats\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForTeams\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForTeams\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Copilot\AddCopilotSeatsForUsers\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Copilot\CancelCopilotSeatAssignmentForUsers\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListOrgSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotPublicKey|\ApiClients\Client\GitHub\Schema\OrganizationDependabotSecret|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\OrgHook|\ApiClients\Client\GitHub\Schema\Operations\Orgs\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAppInstallations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\InteractionLimitResponse|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForOrg\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\OrganizationInvitation|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\GetCodespacesForUserInOrg\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteFromOrganization\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Codespace|\ApiClients\Client\GitHub\Schema\CopilotSeatDetails|\ApiClients\Client\GitHub\Schema\OrgMembership|\ApiClients\Client\GitHub\Schema\Migration|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListOrgRoles\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\OrganizationRole|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ConvertMemberToOutsideCollaborator\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Package|\ApiClients\Client\GitHub\Schema\PackageVersion|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ReviewPatGrantRequestsInBulk\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Orgs\UpdatePatAccesses\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Project|\ApiClients\Client\GitHub\Schema\CustomProperty|\ApiClients\Client\GitHub\Schema\FullRepository|\ApiClients\Client\GitHub\Schema\RepositoryRuleset|\ApiClients\Client\GitHub\Schema\RuleSuite|\ApiClients\Client\GitHub\Schema\ActionsBillingUsage|\ApiClients\Client\GitHub\Schema\PackagesBillingUsage|\ApiClients\Client\GitHub\Schema\CombinedBillingUsage|\ApiClients\Client\GitHub\Schema\TeamFull|\ApiClients\Client\GitHub\Schema\TeamDiscussion|\ApiClients\Client\GitHub\Schema\TeamDiscussionComment|\ApiClients\Client\GitHub\Schema\Reaction|\ApiClients\Client\GitHub\Schema\TeamMembership|\ApiClients\Client\GitHub\Schema\TeamProject|\ApiClients\Client\GitHub\Schema\TeamRepository|\ApiClients\Client\GitHub\Schema\ProjectCard|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveCard\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectColumn|\ApiClients\Client\GitHub\Schema\Operations\Projects\MoveColumn\Response\ApplicationJson\Created\Application\Json|\ApiClients\Client\GitHub\Schema\ProjectCollaboratorPermission|\ApiClients\Client\GitHub\Schema\RateLimitOverview|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListArtifactsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Artifact|\ApiClients\Client\GitHub\Schema\ActionsCacheUsageByRepository|\ApiClients\Client\GitHub\Schema\ActionsCacheList|\ApiClients\Client\GitHub\Schema\Job|\ApiClients\Client\GitHub\Schema\OidcCustomSubRepo|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoOrganizationVariables\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\ActionsRepositoryPermissions|\ApiClients\Client\GitHub\Schema\ActionsWorkflowAccessToRepository|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\RemoveAllCustomLabelsFromSelfHostedRunnerForRepo\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunsForRepo\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\WorkflowRun|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRunArtifacts\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRunAttempt\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRun\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowRunUsage|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsSecret|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ActionsVariable|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListRepoWorkflows\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Workflow|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRuns\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\WorkflowUsage|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateAttestation\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListAttestations\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Autolink|\ApiClients\Client\GitHub\Schema\CheckAutomatedSecurityFixes|\ApiClients\Client\GitHub\Schema\BranchWithProtection|\ApiClients\Client\GitHub\Schema\BranchProtection|\ApiClients\Client\GitHub\Schema\ProtectedBranch|\ApiClients\Client\GitHub\Schema\ProtectedBranchAdminEnforced|\ApiClients\Client\GitHub\Schema\ProtectedBranchPullRequestReview|\ApiClients\Client\GitHub\Schema\StatusCheckPolicy|\ApiClients\Client\GitHub\Schema\BranchRestrictionPolicy|\ApiClients\Client\GitHub\Schema\CheckRun|\ApiClients\Client\GitHub\Schema\CheckSuite|\ApiClients\Client\GitHub\Schema\CheckSuitePreference|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForSuite\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodeScanningAlert|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningAnalysisDeletion|\ApiClients\Client\GitHub\Schema\CodeScanningCodeqlDatabase|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysis|\ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysisRepoTask|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetup|\ApiClients\Client\GitHub\Schema\CodeScanningDefaultSetupUpdateResponse|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsReceipt|\ApiClients\Client\GitHub\Schema\CodeScanningSarifsStatus|\ApiClients\Client\GitHub\Schema\CodeSecurityConfigurationForRepository|\ApiClients\Client\GitHub\Schema\CodeownersErrors|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListInRepositoryForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\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|\ApiClients\Client\GitHub\Schema\CodespacesPermissionsCheckForDevcontainer|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\RepoCodespacesSecret|\ApiClients\Client\GitHub\Schema\RepositoryInvitation|\ApiClients\Client\GitHub\Schema\RepositoryCollaboratorPermission|\ApiClients\Client\GitHub\Schema\CommitComment|\ApiClients\Client\GitHub\Schema\Commit|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForRef\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListSuitesForRef\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CombinedCommitStatus|\ApiClients\Client\GitHub\Schema\CommunityProfile|\ApiClients\Client\GitHub\Schema\CommitComparison|\ApiClients\Client\GitHub\Schema\ContentDirectory|\ApiClients\Client\GitHub\Schema\ContentFile|\ApiClients\Client\GitHub\Schema\ContentSymlink|\ApiClients\Client\GitHub\Schema\ContentSubmodule|\ApiClients\Client\GitHub\Schema\FileCommit|\ApiClients\Client\GitHub\Schema\DependabotAlert|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListRepoSecrets\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DependabotSecret|\ApiClients\Client\GitHub\Schema\DependencyGraphSpdxSbom|\ApiClients\Client\GitHub\Schema\Operations\DependencyGraph\CreateRepositorySnapshot\Response\ApplicationJson\Created|\ApiClients\Client\GitHub\Schema\Deployment|\ApiClients\Client\GitHub\Schema\Operations\Repos\CreateDeployment\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\DeploymentStatus|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllEnvironments\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Environment|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListDeploymentBranchPolicies\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentBranchPolicy|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllDeploymentProtectionRules\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\DeploymentProtectionRule|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListCustomDeploymentRuleIntegrations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentVariables\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\ShortBlob|\ApiClients\Client\GitHub\Schema\Blob|\ApiClients\Client\GitHub\Schema\GitCommit|\ApiClients\Client\GitHub\Schema\GitRef|\ApiClients\Client\GitHub\Schema\GitTag|\ApiClients\Client\GitHub\Schema\GitTree|\ApiClients\Client\GitHub\Schema\Hook|\ApiClients\Client\GitHub\Schema\Operations\Repos\RedeliverWebhookDelivery\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Import|\ApiClients\Client\GitHub\Schema\PorterAuthor|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForRepo\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Issue|\ApiClients\Client\GitHub\Schema\IssueComment|\ApiClients\Client\GitHub\Schema\IssueEvent|\ApiClients\Client\GitHub\Schema\DeployKey|\ApiClients\Client\GitHub\Schema\Label|\ApiClients\Client\GitHub\Schema\Language|\ApiClients\Client\GitHub\Schema\LicenseContent|\ApiClients\Client\GitHub\Schema\MergedUpstream|\ApiClients\Client\GitHub\Schema\Milestone|\ApiClients\Client\GitHub\Schema\Operations\Activity\MarkRepoNotificationsAsRead\Response\ApplicationJson\Accepted|\ApiClients\Client\GitHub\Schema\Page|\ApiClients\Client\GitHub\Schema\PageBuildStatus|\ApiClients\Client\GitHub\Schema\PageBuild|\ApiClients\Client\GitHub\Schema\PageDeployment|\ApiClients\Client\GitHub\Schema\PagesDeploymentStatus|\ApiClients\Client\GitHub\Schema\PagesHealthCheck|\ApiClients\Client\GitHub\Schema\Operations\Repos\CheckPrivateVulnerabilityReporting\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PullRequest|\ApiClients\Client\GitHub\Schema\PullRequestReviewComment|\ApiClients\Client\GitHub\Schema\PullRequestMergeResult|\ApiClients\Client\GitHub\Schema\PullRequestReviewRequest|\ApiClients\Client\GitHub\Schema\PullRequestSimple|\ApiClients\Client\GitHub\Schema\PullRequestReview|\ApiClients\Client\GitHub\Schema\Operations\Pulls\UpdateBranch\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\Release|\ApiClients\Client\GitHub\Schema\ReleaseAsset|\ApiClients\Client\GitHub\Schema\ReleaseNotesContent|\ApiClients\Client\GitHub\Schema\SecretScanningAlert|\ApiClients\Client\GitHub\Schema\SecretScanningPushProtectionBypass|\ApiClients\Client\GitHub\Schema\RepositoryAdvisory|\ApiClients\Client\GitHub\Schema\Operations\SecurityAdvisories\CreateRepositoryAdvisoryCveRequest\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\SimpleUser|\ApiClients\Client\GitHub\Schema\Stargazer|\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|\ApiClients\Client\GitHub\Schema\ParticipationStats|\ApiClients\Client\GitHub\Schema\Status|\ApiClients\Client\GitHub\Schema\RepositorySubscription|\ApiClients\Client\GitHub\Schema\TagProtection|\ApiClients\Client\GitHub\Schema\Topic|\ApiClients\Client\GitHub\Schema\CloneTraffic|\ApiClients\Client\GitHub\Schema\ViewTraffic|\ApiClients\Client\GitHub\Schema\MinimalRepository|\ApiClients\Client\GitHub\Schema\Operations\Search\Code\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Commits\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\IssuesAndPullRequests\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Labels\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Repos\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Topics\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Search\Users\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\PrivateUser|\ApiClients\Client\GitHub\Schema\PublicUser|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSecretsForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\CodespacesUserPublicKey|\ApiClients\Client\GitHub\Schema\CodespacesSecret|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListRepositoriesForSecretForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\DeleteForAuthenticatedUser\Response\ApplicationJson\Accepted\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceExportDetails|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\CodespaceMachinesForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\CodespaceWithFullRepository|\ApiClients\Client\GitHub\Schema\GpgKey|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Apps\ListInstallationReposForAuthenticatedUser\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Interactions\GetRestrictionsForAuthenticatedUser\Response\ApplicationJson\Ok\Application\Json\One|\ApiClients\Client\GitHub\Schema\Key|\ApiClients\Client\GitHub\Schema\SshSigningKey|\ApiClients\Client\GitHub\Schema\Operations\Users\ListAttestations\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Hovercard|\ApiClients\Client\GitHub\Schema\StarredRepository|\ApiClients\Client\GitHub\Schema\Repository; public function operations(): OperationsInterface; diff --git a/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats.php b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats.php new file mode 100644 index 00000000000..084ef271f11 --- /dev/null +++ b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats.php @@ -0,0 +1,248 @@ + $className + * + * @return T + * + * @template T of object + */ + public function hydrateObject(string $className, array $payload): object + { + return match ($className) { + 'ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats' => $this->hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats($payload), + default => throw UnableToHydrateObject::noHydrationDefined($className, $this->hydrationStack), + }; + } + + private function hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats(array $payload): ApiInsightsSummaryStats + { + $properties = []; + $missingFields = []; + try { + $value = $payload['total_request_count'] ?? null; + + if ($value === null) { + $properties['totalRequestCount'] = null; + goto after_totalRequestCount; + } + + $properties['totalRequestCount'] = $value; + + after_totalRequestCount: + + $value = $payload['rate_limited_request_count'] ?? null; + + if ($value === null) { + $properties['rateLimitedRequestCount'] = null; + goto after_rateLimitedRequestCount; + } + + $properties['rateLimitedRequestCount'] = $value; + + after_rateLimitedRequestCount: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats', $exception, stack: $this->hydrationStack); + } + + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(ApiInsightsSummaryStats::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new ApiInsightsSummaryStats(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats', $exception, stack: $this->hydrationStack); + } + } + + private function serializeViaTypeMap(string $accessor, object $object, array $payloadToTypeMap): array + { + foreach ($payloadToTypeMap as $payloadType => [$valueType, $method]) { + if (is_a($object, $valueType)) { + return [$accessor => $payloadType] + $this->{$method}($object); + } + } + + throw new LogicException('No type mapped for object of class: ' . $object::class); + } + + public function serializeObject(object $object): mixed + { + return $this->serializeObjectOfType($object, $object::class); + } + + /** + * @param T $object + * @param class-string $className + * + * @template T + */ + public function serializeObjectOfType(object $object, string $className): mixed + { + try { + return match ($className) { + 'array' => $this->serializeValuearray($object), + 'Ramsey\Uuid\UuidInterface' => $this->serializeValueRamsey⚡️Uuid⚡️UuidInterface($object), + 'DateTime' => $this->serializeValueDateTime($object), + 'DateTimeImmutable' => $this->serializeValueDateTimeImmutable($object), + 'DateTimeInterface' => $this->serializeValueDateTimeInterface($object), + 'ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats' => $this->serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats($object), + default => throw new LogicException("No serialization defined for $className"), + }; + } catch (Throwable $exception) { + throw UnableToSerializeObject::dueToError($className, $exception); + } + } + + private function serializeValuearray(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeArrayItems(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueRamsey⚡️Uuid⚡️UuidInterface(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeUuidToString(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTime(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTimeImmutable(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTimeInterface(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats(mixed $object): mixed + { + assert($object instanceof ApiInsightsSummaryStats); + $result = []; + + $totalRequestCount = $object->totalRequestCount; + + if ($totalRequestCount === null) { + goto after_totalRequestCount; + } + + after_totalRequestCount: $result['total_request_count'] = $totalRequestCount; + + $rateLimitedRequestCount = $object->rateLimitedRequestCount; + + if ($rateLimitedRequestCount === null) { + goto after_rateLimitedRequestCount; + } + + after_rateLimitedRequestCount: $result['rate_limited_request_count'] = $rateLimitedRequestCount; + + return $result; + } + + /** + * @param class-string $className + * @param iterable $payloads; + * + * @return IterableList + * + * @throws UnableToHydrateObject + * + * @template T + */ + public function hydrateObjects(string $className, iterable $payloads): IterableList + { + return new IterableList($this->doHydrateObjects($className, $payloads)); + } + + private function doHydrateObjects(string $className, iterable $payloads): Generator + { + foreach ($payloads as $index => $payload) { + yield $index => $this->hydrateObject($className, $payload); + } + } + + /** + * @param class-string $className + * @param iterable $payloads; + * + * @return IterableList + * + * @throws UnableToSerializeObject + * + * @template T + */ + public function serializeObjects(iterable $payloads): IterableList + { + return new IterableList($this->doSerializeObjects($payloads)); + } + + private function doSerializeObjects(iterable $objects): Generator + { + foreach ($objects as $index => $object) { + yield $index => $this->serializeObject($object); + } + } +} diff --git a/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/ActorType/ActorId.php b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/ActorType/ActorId.php new file mode 100644 index 00000000000..24a4f00cc15 --- /dev/null +++ b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/ActorType/ActorId.php @@ -0,0 +1,248 @@ + $className + * + * @return T + * + * @template T of object + */ + public function hydrateObject(string $className, array $payload): object + { + return match ($className) { + 'ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats' => $this->hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats($payload), + default => throw UnableToHydrateObject::noHydrationDefined($className, $this->hydrationStack), + }; + } + + private function hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats(array $payload): ApiInsightsSummaryStats + { + $properties = []; + $missingFields = []; + try { + $value = $payload['total_request_count'] ?? null; + + if ($value === null) { + $properties['totalRequestCount'] = null; + goto after_totalRequestCount; + } + + $properties['totalRequestCount'] = $value; + + after_totalRequestCount: + + $value = $payload['rate_limited_request_count'] ?? null; + + if ($value === null) { + $properties['rateLimitedRequestCount'] = null; + goto after_rateLimitedRequestCount; + } + + $properties['rateLimitedRequestCount'] = $value; + + after_rateLimitedRequestCount: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats', $exception, stack: $this->hydrationStack); + } + + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(ApiInsightsSummaryStats::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new ApiInsightsSummaryStats(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats', $exception, stack: $this->hydrationStack); + } + } + + private function serializeViaTypeMap(string $accessor, object $object, array $payloadToTypeMap): array + { + foreach ($payloadToTypeMap as $payloadType => [$valueType, $method]) { + if (is_a($object, $valueType)) { + return [$accessor => $payloadType] + $this->{$method}($object); + } + } + + throw new LogicException('No type mapped for object of class: ' . $object::class); + } + + public function serializeObject(object $object): mixed + { + return $this->serializeObjectOfType($object, $object::class); + } + + /** + * @param T $object + * @param class-string $className + * + * @template T + */ + public function serializeObjectOfType(object $object, string $className): mixed + { + try { + return match ($className) { + 'array' => $this->serializeValuearray($object), + 'Ramsey\Uuid\UuidInterface' => $this->serializeValueRamsey⚡️Uuid⚡️UuidInterface($object), + 'DateTime' => $this->serializeValueDateTime($object), + 'DateTimeImmutable' => $this->serializeValueDateTimeImmutable($object), + 'DateTimeInterface' => $this->serializeValueDateTimeInterface($object), + 'ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats' => $this->serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats($object), + default => throw new LogicException("No serialization defined for $className"), + }; + } catch (Throwable $exception) { + throw UnableToSerializeObject::dueToError($className, $exception); + } + } + + private function serializeValuearray(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeArrayItems(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueRamsey⚡️Uuid⚡️UuidInterface(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeUuidToString(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTime(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTimeImmutable(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTimeInterface(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats(mixed $object): mixed + { + assert($object instanceof ApiInsightsSummaryStats); + $result = []; + + $totalRequestCount = $object->totalRequestCount; + + if ($totalRequestCount === null) { + goto after_totalRequestCount; + } + + after_totalRequestCount: $result['total_request_count'] = $totalRequestCount; + + $rateLimitedRequestCount = $object->rateLimitedRequestCount; + + if ($rateLimitedRequestCount === null) { + goto after_rateLimitedRequestCount; + } + + after_rateLimitedRequestCount: $result['rate_limited_request_count'] = $rateLimitedRequestCount; + + return $result; + } + + /** + * @param class-string $className + * @param iterable $payloads; + * + * @return IterableList + * + * @throws UnableToHydrateObject + * + * @template T + */ + public function hydrateObjects(string $className, iterable $payloads): IterableList + { + return new IterableList($this->doHydrateObjects($className, $payloads)); + } + + private function doHydrateObjects(string $className, iterable $payloads): Generator + { + foreach ($payloads as $index => $payload) { + yield $index => $this->hydrateObject($className, $payload); + } + } + + /** + * @param class-string $className + * @param iterable $payloads; + * + * @return IterableList + * + * @throws UnableToSerializeObject + * + * @template T + */ + public function serializeObjects(iterable $payloads): IterableList + { + return new IterableList($this->doSerializeObjects($payloads)); + } + + private function doSerializeObjects(iterable $objects): Generator + { + foreach ($objects as $index => $object) { + yield $index => $this->serializeObject($object); + } + } +} diff --git a/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/Users/UserId.php b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/Users/UserId.php new file mode 100644 index 00000000000..678f52c232e --- /dev/null +++ b/clients/GitHub/src/Internal/Hydrator/Operation/Orgs/Org/Insights/Api/SummaryStats/Users/UserId.php @@ -0,0 +1,248 @@ + $className + * + * @return T + * + * @template T of object + */ + public function hydrateObject(string $className, array $payload): object + { + return match ($className) { + 'ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats' => $this->hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats($payload), + default => throw UnableToHydrateObject::noHydrationDefined($className, $this->hydrationStack), + }; + } + + private function hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats(array $payload): ApiInsightsSummaryStats + { + $properties = []; + $missingFields = []; + try { + $value = $payload['total_request_count'] ?? null; + + if ($value === null) { + $properties['totalRequestCount'] = null; + goto after_totalRequestCount; + } + + $properties['totalRequestCount'] = $value; + + after_totalRequestCount: + + $value = $payload['rate_limited_request_count'] ?? null; + + if ($value === null) { + $properties['rateLimitedRequestCount'] = null; + goto after_rateLimitedRequestCount; + } + + $properties['rateLimitedRequestCount'] = $value; + + after_rateLimitedRequestCount: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats', $exception, stack: $this->hydrationStack); + } + + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(ApiInsightsSummaryStats::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new ApiInsightsSummaryStats(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats', $exception, stack: $this->hydrationStack); + } + } + + private function serializeViaTypeMap(string $accessor, object $object, array $payloadToTypeMap): array + { + foreach ($payloadToTypeMap as $payloadType => [$valueType, $method]) { + if (is_a($object, $valueType)) { + return [$accessor => $payloadType] + $this->{$method}($object); + } + } + + throw new LogicException('No type mapped for object of class: ' . $object::class); + } + + public function serializeObject(object $object): mixed + { + return $this->serializeObjectOfType($object, $object::class); + } + + /** + * @param T $object + * @param class-string $className + * + * @template T + */ + public function serializeObjectOfType(object $object, string $className): mixed + { + try { + return match ($className) { + 'array' => $this->serializeValuearray($object), + 'Ramsey\Uuid\UuidInterface' => $this->serializeValueRamsey⚡️Uuid⚡️UuidInterface($object), + 'DateTime' => $this->serializeValueDateTime($object), + 'DateTimeImmutable' => $this->serializeValueDateTimeImmutable($object), + 'DateTimeInterface' => $this->serializeValueDateTimeInterface($object), + 'ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats' => $this->serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats($object), + default => throw new LogicException("No serialization defined for $className"), + }; + } catch (Throwable $exception) { + throw UnableToSerializeObject::dueToError($className, $exception); + } + } + + private function serializeValuearray(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeArrayItems(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueRamsey⚡️Uuid⚡️UuidInterface(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeUuidToString(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTime(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTimeImmutable(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeValueDateTimeInterface(mixed $value): mixed + { + static $serializer; + + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } + + return $serializer->serialize($value, $this); + } + + private function serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema⚡️ApiInsightsSummaryStats(mixed $object): mixed + { + assert($object instanceof ApiInsightsSummaryStats); + $result = []; + + $totalRequestCount = $object->totalRequestCount; + + if ($totalRequestCount === null) { + goto after_totalRequestCount; + } + + after_totalRequestCount: $result['total_request_count'] = $totalRequestCount; + + $rateLimitedRequestCount = $object->rateLimitedRequestCount; + + if ($rateLimitedRequestCount === null) { + goto after_rateLimitedRequestCount; + } + + after_rateLimitedRequestCount: $result['rate_limited_request_count'] = $rateLimitedRequestCount; + + return $result; + } + + /** + * @param class-string $className + * @param iterable $payloads; + * + * @return IterableList + * + * @throws UnableToHydrateObject + * + * @template T + */ + public function hydrateObjects(string $className, iterable $payloads): IterableList + { + return new IterableList($this->doHydrateObjects($className, $payloads)); + } + + private function doHydrateObjects(string $className, iterable $payloads): Generator + { + foreach ($payloads as $index => $payload) { + yield $index => $this->hydrateObject($className, $payload); + } + } + + /** + * @param class-string $className + * @param iterable $payloads; + * + * @return IterableList + * + * @throws UnableToSerializeObject + * + * @template T + */ + public function serializeObjects(iterable $payloads): IterableList + { + return new IterableList($this->doSerializeObjects($payloads)); + } + + private function doSerializeObjects(iterable $objects): Generator + { + foreach ($objects as $index => $object) { + yield $index => $this->serializeObject($object); + } + } +} diff --git a/clients/GitHub/src/Internal/Hydrator/WebHook/PersonalAccessTokenRequest.php b/clients/GitHub/src/Internal/Hydrator/WebHook/PersonalAccessTokenRequest.php index 0f7f6ca8a53..55c12e8963d 100644 --- a/clients/GitHub/src/Internal/Hydrator/WebHook/PersonalAccessTokenRequest.php +++ b/clients/GitHub/src/Internal/Hydrator/WebHook/PersonalAccessTokenRequest.php @@ -348,6 +348,17 @@ private function hydrateApiClients⚡️Client⚡️GitHub⚡️Schema⚡️Pers after_createdAt: + $value = $payload['token_id'] ?? null; + + if ($value === null) { + $missingFields[] = 'token_id'; + goto after_tokenId; + } + + $properties['tokenId'] = $value; + + after_tokenId: + $value = $payload['token_expired'] ?? null; if ($value === null) { @@ -1978,6 +1989,9 @@ private function serializeObjectApiClients⚡️Client⚡️GitHub⚡️Schema $createdAt = $object->createdAt; after_createdAt: $result['created_at'] = $createdAt; + $tokenId = $object->tokenId; + after_tokenId: $result['token_id'] = $tokenId; + $tokenExpired = $object->tokenExpired; after_tokenExpired: $result['token_expired'] = $tokenExpired; diff --git a/clients/GitHub/src/Internal/Hydrators.php b/clients/GitHub/src/Internal/Hydrators.php index 63ece4321df..543202e7250 100644 --- a/clients/GitHub/src/Internal/Hydrators.php +++ b/clients/GitHub/src/Internal/Hydrators.php @@ -152,6 +152,15 @@ final class Hydrators implements ObjectMapper private Internal\Hydrator\Operation\Orgs\Org\Hooks\HookId\Deliveries\DeliveryId|null $operation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Deliveries🌀DeliveryId = null; private Internal\Hydrator\Operation\Orgs\Org\Hooks\HookId\Deliveries\DeliveryId\Attempts|null $operation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Deliveries🌀DeliveryId🌀Attempts = null; private Internal\Hydrator\Operation\Orgs\Org\Hooks\HookId\Pings|null $operation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Pings = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\RouteStats\ActorType\ActorId|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SubjectStats|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\Users\UserId|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀Users🌀UserId = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\ActorType\ActorId|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀ActorType🌀ActorId = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\Users\UserId|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀Users🌀UserId = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\ActorType\ActorId|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀ActorType🌀ActorId = null; + private Internal\Hydrator\Operation\Orgs\Org\Insights\Api\UserStats\UserId|null $operation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId = null; private Internal\Hydrator\Operation\Orgs\Org\Installation|null $operation🌀Orgs🌀Org🌀Installation = null; private Internal\Hydrator\Operation\Orgs\Org\Installations|null $operation🌀Orgs🌀Org🌀Installations = null; private Internal\Hydrator\Operation\Orgs\Org\InteractionLimits|null $operation🌀Orgs🌀Org🌀InteractionLimits = null; @@ -801,6 +810,7 @@ public function hydrateObject(string $className, array $payload): object '\\ApiClients\\Client\\GitHub\\Schema\\Operations\\Dependabot\\ListSelectedReposForOrgSecret\\Response\\ApplicationJson\\Ok\\Application\\Json' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Dependabot🌀Secrets🌀SecretName🌀Repositories()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHub\\Schema\\OrgHook', '\\ApiClients\\Client\\GitHub\\Schema\\OrgHook\\Config' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Hooks()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHub\\Schema\\Operations\\Orgs\\RedeliverWebhookDelivery\\Response\\ApplicationJson\\Accepted\\Application\\Json' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Deliveries🌀DeliveryId🌀Attempts()->hydrateObject($className, $payload), + '\\ApiClients\\Client\\GitHub\\Schema\\ApiInsightsSummaryStats' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHub\\Schema\\Operations\\Orgs\\ListAppInstallations\\Response\\ApplicationJson\\Ok' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Installations()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHub\\Schema\\InteractionLimitResponse' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀InteractionLimits()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHub\\Schema\\OrganizationInvitation' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Invitations()->hydrateObject($className, $payload), @@ -1159,6 +1169,7 @@ public function serializeObjectOfType(object $object, string $className): mixed '\\ApiClients\\Client\\GitHub\\Schema\\Operations\\Dependabot\\ListSelectedReposForOrgSecret\\Response\\ApplicationJson\\Ok\\Application\\Json' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Dependabot🌀Secrets🌀SecretName🌀Repositories()->serializeObject($object), '\\ApiClients\\Client\\GitHub\\Schema\\OrgHook', '\\ApiClients\\Client\\GitHub\\Schema\\OrgHook\\Config' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Hooks()->serializeObject($object), '\\ApiClients\\Client\\GitHub\\Schema\\Operations\\Orgs\\RedeliverWebhookDelivery\\Response\\ApplicationJson\\Accepted\\Application\\Json' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Deliveries🌀DeliveryId🌀Attempts()->serializeObject($object), + '\\ApiClients\\Client\\GitHub\\Schema\\ApiInsightsSummaryStats' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats()->serializeObject($object), '\\ApiClients\\Client\\GitHub\\Schema\\Operations\\Orgs\\ListAppInstallations\\Response\\ApplicationJson\\Ok' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Installations()->serializeObject($object), '\\ApiClients\\Client\\GitHub\\Schema\\InteractionLimitResponse' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀InteractionLimits()->serializeObject($object), '\\ApiClients\\Client\\GitHub\\Schema\\OrganizationInvitation' => $this->getObjectMapperOperation🌀Orgs🌀Org🌀Invitations()->serializeObject($object), @@ -2707,6 +2718,87 @@ public function getObjectMapperOperation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Pi return $this->operation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Pings; } + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\RouteStats\ActorType\ActorId + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\RouteStats\ActorType\ActorId === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\RouteStats\ActorType\ActorId(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SubjectStats + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SubjectStats === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SubjectStats(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀Users🌀UserId(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\Users\UserId + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀Users🌀UserId instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\Users\UserId === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀Users🌀UserId = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\Users\UserId(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀Users🌀UserId; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀ActorType🌀ActorId(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\ActorType\ActorId + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀ActorType🌀ActorId instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\ActorType\ActorId === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀ActorType🌀ActorId = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\SummaryStats\ActorType\ActorId(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀ActorType🌀ActorId; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀Users🌀UserId(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\Users\UserId + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀Users🌀UserId instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\Users\UserId === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀Users🌀UserId = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\Users\UserId(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀Users🌀UserId; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀ActorType🌀ActorId(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\ActorType\ActorId + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀ActorType🌀ActorId instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\ActorType\ActorId === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀ActorType🌀ActorId = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\TimeStats\ActorType\ActorId(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀ActorType🌀ActorId; + } + + public function getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId(): Internal\Hydrator\Operation\Orgs\Org\Insights\Api\UserStats\UserId + { + if ($this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId instanceof Internal\Hydrator\Operation\Orgs\Org\Insights\Api\UserStats\UserId === false) { + $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId = new Internal\Hydrator\Operation\Orgs\Org\Insights\Api\UserStats\UserId(); + } + + return $this->operation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId; + } + public function getObjectMapperOperation🌀Orgs🌀Org🌀Installation(): Internal\Hydrator\Operation\Orgs\Org\Installation { if ($this->operation🌀Orgs🌀Org🌀Installation instanceof Internal\Hydrator\Operation\Orgs\Org\Installation === false) { diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActor.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActor.php new file mode 100644 index 00000000000..b49b3665232 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActor.php @@ -0,0 +1,97 @@ +org = $org; + $this->actorType = $actorType; + $this->actorId = $actorId; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->sort = $sort; + $this->page = $page; + $this->perPage = $perPage; + $this->direction = $direction; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{actor_type}', '{actor_id}', '{min_timestamp}', '{max_timestamp}', '{sort}', '{page}', '{per_page}', '{direction}'], [$this->org, $this->actorType, $this->actorId, $this->minTimestamp, $this->maxTimestamp, $this->sort, $this->page, $this->perPage, $this->direction], '/orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}&sort={sort}&page={page}&per_page={per_page}&direction={direction}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsRouteStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsRouteStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsRouteStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActorListing.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActorListing.php new file mode 100644 index 00000000000..8cf5ffd3eab --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetRouteStatsByActorListing.php @@ -0,0 +1,97 @@ +org = $org; + $this->actorType = $actorType; + $this->actorId = $actorId; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->sort = $sort; + $this->page = $page; + $this->perPage = $perPage; + $this->direction = $direction; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{actor_type}', '{actor_id}', '{min_timestamp}', '{max_timestamp}', '{sort}', '{page}', '{per_page}', '{direction}'], [$this->org, $this->actorType, $this->actorId, $this->minTimestamp, $this->maxTimestamp, $this->sort, $this->page, $this->perPage, $this->direction], '/orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}&sort={sort}&page={page}&per_page={per_page}&direction={direction}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsRouteStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsRouteStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsRouteStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStats.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStats.php new file mode 100644 index 00000000000..9e2aca9bb86 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStats.php @@ -0,0 +1,91 @@ +org = $org; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->sort = $sort; + $this->page = $page; + $this->perPage = $perPage; + $this->direction = $direction; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{min_timestamp}', '{max_timestamp}', '{sort}', '{page}', '{per_page}', '{direction}'], [$this->org, $this->minTimestamp, $this->maxTimestamp, $this->sort, $this->page, $this->perPage, $this->direction], '/orgs/{org}/insights/api/subject-stats' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}&sort={sort}&page={page}&per_page={per_page}&direction={direction}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsSubjectStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsSubjectStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsSubjectStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStatsListing.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStatsListing.php new file mode 100644 index 00000000000..8ea9cc71f39 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSubjectStatsListing.php @@ -0,0 +1,91 @@ +org = $org; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->sort = $sort; + $this->page = $page; + $this->perPage = $perPage; + $this->direction = $direction; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{min_timestamp}', '{max_timestamp}', '{sort}', '{page}', '{per_page}', '{direction}'], [$this->org, $this->minTimestamp, $this->maxTimestamp, $this->sort, $this->page, $this->perPage, $this->direction], '/orgs/{org}/insights/api/subject-stats' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}&sort={sort}&page={page}&per_page={per_page}&direction={direction}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsSubjectStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsSubjectStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsSubjectStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStats.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStats.php new file mode 100644 index 00000000000..6c7a2077640 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStats.php @@ -0,0 +1,65 @@ +org = $org; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{min_timestamp}', '{max_timestamp}'], [$this->org, $this->minTimestamp, $this->maxTimestamp], '/orgs/{org}/insights/api/summary-stats' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}')); + } + + public function createResponse(ResponseInterface $response): Schema\ApiInsightsSummaryStats + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsSummaryStats::SCHEMA_JSON, \cebe\openapi\spec\Schema::class)); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsSummaryStats::class, $body); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByActor.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByActor.php new file mode 100644 index 00000000000..91153d612e9 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByActor.php @@ -0,0 +1,71 @@ +org = $org; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->actorType = $actorType; + $this->actorId = $actorId; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{min_timestamp}', '{max_timestamp}', '{actor_type}', '{actor_id}'], [$this->org, $this->minTimestamp, $this->maxTimestamp, $this->actorType, $this->actorId], '/orgs/{org}/insights/api/summary-stats/{actor_type}/{actor_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}')); + } + + public function createResponse(ResponseInterface $response): Schema\ApiInsightsSummaryStats + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsSummaryStats::SCHEMA_JSON, \cebe\openapi\spec\Schema::class)); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsSummaryStats::class, $body); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByUser.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByUser.php new file mode 100644 index 00000000000..af53d8cbcb8 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetSummaryStatsByUser.php @@ -0,0 +1,68 @@ +org = $org; + $this->userId = $userId; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{user_id}', '{min_timestamp}', '{max_timestamp}'], [$this->org, $this->userId, $this->minTimestamp, $this->maxTimestamp], '/orgs/{org}/insights/api/summary-stats/users/{user_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}')); + } + + public function createResponse(ResponseInterface $response): Schema\ApiInsightsSummaryStats + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsSummaryStats::SCHEMA_JSON, \cebe\openapi\spec\Schema::class)); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsSummaryStats::class, $body); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStats.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStats.php new file mode 100644 index 00000000000..186f9f478b7 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStats.php @@ -0,0 +1,82 @@ +org = $org; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->timestampIncrement = $timestampIncrement; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{min_timestamp}', '{max_timestamp}', '{timestamp_increment}'], [$this->org, $this->minTimestamp, $this->maxTimestamp, $this->timestampIncrement], '/orgs/{org}/insights/api/time-stats' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}×tamp_increment={timestamp_increment}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsTimeStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsTimeStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsTimeStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByActor.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByActor.php new file mode 100644 index 00000000000..7c021e887c1 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByActor.php @@ -0,0 +1,88 @@ +org = $org; + $this->actorType = $actorType; + $this->actorId = $actorId; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->timestampIncrement = $timestampIncrement; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{actor_type}', '{actor_id}', '{min_timestamp}', '{max_timestamp}', '{timestamp_increment}'], [$this->org, $this->actorType, $this->actorId, $this->minTimestamp, $this->maxTimestamp, $this->timestampIncrement], '/orgs/{org}/insights/api/time-stats/{actor_type}/{actor_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}×tamp_increment={timestamp_increment}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsTimeStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsTimeStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsTimeStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByUser.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByUser.php new file mode 100644 index 00000000000..eca3f2262ea --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetTimeStatsByUser.php @@ -0,0 +1,85 @@ +org = $org; + $this->userId = $userId; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->timestampIncrement = $timestampIncrement; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{user_id}', '{min_timestamp}', '{max_timestamp}', '{timestamp_increment}'], [$this->org, $this->userId, $this->minTimestamp, $this->maxTimestamp, $this->timestampIncrement], '/orgs/{org}/insights/api/time-stats/users/{user_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}×tamp_increment={timestamp_increment}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsTimeStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsTimeStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsTimeStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStats.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStats.php new file mode 100644 index 00000000000..1f35cc466c1 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStats.php @@ -0,0 +1,94 @@ +org = $org; + $this->userId = $userId; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->sort = $sort; + $this->page = $page; + $this->perPage = $perPage; + $this->direction = $direction; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{user_id}', '{min_timestamp}', '{max_timestamp}', '{sort}', '{page}', '{per_page}', '{direction}'], [$this->org, $this->userId, $this->minTimestamp, $this->maxTimestamp, $this->sort, $this->page, $this->perPage, $this->direction], '/orgs/{org}/insights/api/user-stats/{user_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}&sort={sort}&page={page}&per_page={per_page}&direction={direction}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsUserStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsUserStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsUserStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStatsListing.php b/clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStatsListing.php new file mode 100644 index 00000000000..1a28efed5f2 --- /dev/null +++ b/clients/GitHub/src/Internal/Operation/ApiInsights/GetUserStatsListing.php @@ -0,0 +1,94 @@ +org = $org; + $this->userId = $userId; + $this->minTimestamp = $minTimestamp; + $this->maxTimestamp = $maxTimestamp; + $this->sort = $sort; + $this->page = $page; + $this->perPage = $perPage; + $this->direction = $direction; + } + + public function createRequest(): RequestInterface + { + return new Request('GET', str_replace(['{org}', '{user_id}', '{min_timestamp}', '{max_timestamp}', '{sort}', '{page}', '{per_page}', '{direction}'], [$this->org, $this->userId, $this->minTimestamp, $this->maxTimestamp, $this->sort, $this->page, $this->perPage, $this->direction], '/orgs/{org}/insights/api/user-stats/{user_id}' . '?min_timestamp={min_timestamp}&max_timestamp={max_timestamp}&sort={sort}&page={page}&per_page={per_page}&direction={direction}')); + } + + /** @return Observable */ + public function createResponse(ResponseInterface $response): Observable + { + $code = $response->getStatusCode(); + [$contentType] = explode(';', $response->getHeaderLine('Content-Type')); + switch ($contentType) { + case 'application/json': + $body = json_decode($response->getBody()->getContents(), true); + switch ($code) { + /** + * Response + **/ + case 200: + return Observable::fromArray($body, new ImmediateScheduler())->map(function (array $body): Schema\ApiInsightsUserStats { + $error = new RuntimeException(); + try { + $this->responseSchemaValidator->validate($body, Reader::readFromJson(Schema\ApiInsightsUserStats::SCHEMA_JSON, '\\cebe\\openapi\\spec\\Schema')); + + return $this->hydrator->hydrateObject(Schema\ApiInsightsUserStats::class, $body); + } catch (Throwable $error) { + goto items_application_json_two_hundred_aaaaa; + } + + items_application_json_two_hundred_aaaaa: + throw $error; + }); + } + + break; + } + + throw new RuntimeException('Unable to find matching response code and content type'); + } +} diff --git a/clients/GitHub/src/Internal/Operation/Apps/ListWebhookDeliveries.php b/clients/GitHub/src/Internal/Operation/Apps/ListWebhookDeliveries.php index ab07d7fb0cd..697873a036e 100644 --- a/clients/GitHub/src/Internal/Operation/Apps/ListWebhookDeliveries.php +++ b/clients/GitHub/src/Internal/Operation/Apps/ListWebhookDeliveries.php @@ -30,7 +30,7 @@ final class ListWebhookDeliveries /**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)." **/ private int $perPage; - public function __construct(private readonly SchemaValidator $responseSchemaValidator, private readonly Internal\Hydrator\Operation\App\Hook\Deliveries $hydrator, string $cursor, private bool $redelivery, int $perPage = 30) + public function __construct(private readonly SchemaValidator $responseSchemaValidator, private readonly Internal\Hydrator\Operation\App\Hook\Deliveries $hydrator, string $cursor, int $perPage = 30) { $this->cursor = $cursor; $this->perPage = $perPage; @@ -38,7 +38,7 @@ public function __construct(private readonly SchemaValidator $responseSchemaVali public function createRequest(): RequestInterface { - return new Request('GET', str_replace(['{cursor}', '{redelivery}', '{per_page}'], [$this->cursor, $this->redelivery, $this->perPage], '/app/hook/deliveries' . '?cursor={cursor}&redelivery={redelivery}&per_page={per_page}')); + return new Request('GET', str_replace(['{cursor}', '{per_page}'], [$this->cursor, $this->perPage], '/app/hook/deliveries' . '?cursor={cursor}&per_page={per_page}')); } /** @return Observable */ diff --git a/clients/GitHub/src/Internal/Operation/Orgs/ListWebhookDeliveries.php b/clients/GitHub/src/Internal/Operation/Orgs/ListWebhookDeliveries.php index c658816ba28..c84aa69a9c3 100644 --- a/clients/GitHub/src/Internal/Operation/Orgs/ListWebhookDeliveries.php +++ b/clients/GitHub/src/Internal/Operation/Orgs/ListWebhookDeliveries.php @@ -34,7 +34,7 @@ final class ListWebhookDeliveries /**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)." **/ private int $perPage; - public function __construct(private readonly SchemaValidator $responseSchemaValidator, private readonly Internal\Hydrator\Operation\Orgs\Org\Hooks\HookId\Deliveries $hydrator, string $org, int $hookId, string $cursor, private bool $redelivery, int $perPage = 30) + public function __construct(private readonly SchemaValidator $responseSchemaValidator, private readonly Internal\Hydrator\Operation\Orgs\Org\Hooks\HookId\Deliveries $hydrator, string $org, int $hookId, string $cursor, int $perPage = 30) { $this->org = $org; $this->hookId = $hookId; @@ -44,7 +44,7 @@ public function __construct(private readonly SchemaValidator $responseSchemaVali public function createRequest(): RequestInterface { - return new Request('GET', str_replace(['{org}', '{hook_id}', '{cursor}', '{redelivery}', '{per_page}'], [$this->org, $this->hookId, $this->cursor, $this->redelivery, $this->perPage], '/orgs/{org}/hooks/{hook_id}/deliveries' . '?cursor={cursor}&redelivery={redelivery}&per_page={per_page}')); + return new Request('GET', str_replace(['{org}', '{hook_id}', '{cursor}', '{per_page}'], [$this->org, $this->hookId, $this->cursor, $this->perPage], '/orgs/{org}/hooks/{hook_id}/deliveries' . '?cursor={cursor}&per_page={per_page}')); } /** @return Observable */ diff --git a/clients/GitHub/src/Internal/Operation/Repos/ListWebhookDeliveries.php b/clients/GitHub/src/Internal/Operation/Repos/ListWebhookDeliveries.php index dac63f14f29..a3ccaa27ef0 100644 --- a/clients/GitHub/src/Internal/Operation/Repos/ListWebhookDeliveries.php +++ b/clients/GitHub/src/Internal/Operation/Repos/ListWebhookDeliveries.php @@ -36,7 +36,7 @@ final class ListWebhookDeliveries /**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)." **/ private int $perPage; - public function __construct(private readonly SchemaValidator $responseSchemaValidator, private readonly Internal\Hydrator\Operation\Repos\Owner\Repo\Hooks\HookId\Deliveries $hydrator, string $owner, string $repo, int $hookId, string $cursor, private bool $redelivery, int $perPage = 30) + public function __construct(private readonly SchemaValidator $responseSchemaValidator, private readonly Internal\Hydrator\Operation\Repos\Owner\Repo\Hooks\HookId\Deliveries $hydrator, string $owner, string $repo, int $hookId, string $cursor, int $perPage = 30) { $this->owner = $owner; $this->repo = $repo; @@ -47,7 +47,7 @@ public function __construct(private readonly SchemaValidator $responseSchemaVali public function createRequest(): RequestInterface { - return new Request('GET', str_replace(['{owner}', '{repo}', '{hook_id}', '{cursor}', '{redelivery}', '{per_page}'], [$this->owner, $this->repo, $this->hookId, $this->cursor, $this->redelivery, $this->perPage], '/repos/{owner}/{repo}/hooks/{hook_id}/deliveries' . '?cursor={cursor}&redelivery={redelivery}&per_page={per_page}')); + return new Request('GET', str_replace(['{owner}', '{repo}', '{hook_id}', '{cursor}', '{per_page}'], [$this->owner, $this->repo, $this->hookId, $this->cursor, $this->perPage], '/repos/{owner}/{repo}/hooks/{hook_id}/deliveries' . '?cursor={cursor}&per_page={per_page}')); } /** @return Observable */ diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActor.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActor.php new file mode 100644 index 00000000000..6895758d6f3 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActor.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $actorType, int $actorId, string $minTimestamp, string $maxTimestamp, array $sort, int $page = 1, int $perPage = 30, string $direction = 'desc'): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetRouteStatsByActor($this->responseSchemaValidator, $this->hydrator, $org, $actorType, $actorId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActorListing.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActorListing.php new file mode 100644 index 00000000000..4f9d4c83f13 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetRouteStatsByActorListing.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $actorType, int $actorId, string $minTimestamp, string $maxTimestamp, array $sort, int $page = 1, int $perPage = 30, string $direction = 'desc'): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetRouteStatsByActorListing($this->responseSchemaValidator, $this->hydrator, $org, $actorType, $actorId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStats.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStats.php new file mode 100644 index 00000000000..58a610bcd85 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStats.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $minTimestamp, string $maxTimestamp, array $sort, int $page = 1, int $perPage = 30, string $direction = 'desc'): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetSubjectStats($this->responseSchemaValidator, $this->hydrator, $org, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStatsListing.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStatsListing.php new file mode 100644 index 00000000000..32b12e4ad07 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSubjectStatsListing.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $minTimestamp, string $maxTimestamp, array $sort, int $page = 1, int $perPage = 30, string $direction = 'desc'): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetSubjectStatsListing($this->responseSchemaValidator, $this->hydrator, $org, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStats.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStats.php new file mode 100644 index 00000000000..771d6bbe69a --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStats.php @@ -0,0 +1,40 @@ +responseSchemaValidator, $this->hydrator, $org, $minTimestamp, $maxTimestamp); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): ApiInsightsSummaryStats { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByActor.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByActor.php new file mode 100644 index 00000000000..f980b3aa240 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByActor.php @@ -0,0 +1,40 @@ +responseSchemaValidator, $this->hydrator, $org, $minTimestamp, $maxTimestamp, $actorType, $actorId); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): ApiInsightsSummaryStats { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByUser.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByUser.php new file mode 100644 index 00000000000..ab9b5057fc8 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetSummaryStatsByUser.php @@ -0,0 +1,40 @@ +responseSchemaValidator, $this->hydrator, $org, $userId, $minTimestamp, $maxTimestamp); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): ApiInsightsSummaryStats { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStats.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStats.php new file mode 100644 index 00000000000..e667da11274 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStats.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $minTimestamp, string $maxTimestamp, string $timestampIncrement): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetTimeStats($this->responseSchemaValidator, $this->hydrator, $org, $minTimestamp, $maxTimestamp, $timestampIncrement); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByActor.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByActor.php new file mode 100644 index 00000000000..b3b2b36d739 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByActor.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $actorType, int $actorId, string $minTimestamp, string $maxTimestamp, string $timestampIncrement): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetTimeStatsByActor($this->responseSchemaValidator, $this->hydrator, $org, $actorType, $actorId, $minTimestamp, $maxTimestamp, $timestampIncrement); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByUser.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByUser.php new file mode 100644 index 00000000000..2482b975da0 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetTimeStatsByUser.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $userId, string $minTimestamp, string $maxTimestamp, string $timestampIncrement): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetTimeStatsByUser($this->responseSchemaValidator, $this->hydrator, $org, $userId, $minTimestamp, $maxTimestamp, $timestampIncrement); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStats.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStats.php new file mode 100644 index 00000000000..5e1f331b334 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStats.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $userId, string $minTimestamp, string $maxTimestamp, array $sort, int $page = 1, int $perPage = 30, string $direction = 'desc'): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetUserStats($this->responseSchemaValidator, $this->hydrator, $org, $userId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStatsListing.php b/clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStatsListing.php new file mode 100644 index 00000000000..3564910caa9 --- /dev/null +++ b/clients/GitHub/src/Internal/Operator/ApiInsights/GetUserStatsListing.php @@ -0,0 +1,41 @@ + */ + public function call(string $org, string $userId, string $minTimestamp, string $maxTimestamp, array $sort, int $page = 1, int $perPage = 30, string $direction = 'desc'): iterable + { + $operation = new \ApiClients\Client\GitHub\Internal\Operation\ApiInsights\GetUserStatsListing($this->responseSchemaValidator, $this->hydrator, $org, $userId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + $request = $operation->createRequest(); + $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { + return $operation->createResponse($response); + })); + if ($result instanceof Observable) { + $result = awaitObservable($result); + } + + return $result; + } +} diff --git a/clients/GitHub/src/Internal/Operator/Apps/ListWebhookDeliveries.php b/clients/GitHub/src/Internal/Operator/Apps/ListWebhookDeliveries.php index 02c2860353e..80ccb3de539 100644 --- a/clients/GitHub/src/Internal/Operator/Apps/ListWebhookDeliveries.php +++ b/clients/GitHub/src/Internal/Operator/Apps/ListWebhookDeliveries.php @@ -24,10 +24,10 @@ public function __construct(private Browser $browser, private AuthenticationInte { } - /** @return Observable */ - public function call(string $cursor, bool $redelivery, int $perPage = 30): iterable + /** @return iterable */ + public function call(string $cursor, int $perPage = 30): iterable { - $operation = new \ApiClients\Client\GitHub\Internal\Operation\Apps\ListWebhookDeliveries($this->responseSchemaValidator, $this->hydrator, $cursor, $redelivery, $perPage); + $operation = new \ApiClients\Client\GitHub\Internal\Operation\Apps\ListWebhookDeliveries($this->responseSchemaValidator, $this->hydrator, $cursor, $perPage); $request = $operation->createRequest(); $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { return $operation->createResponse($response); diff --git a/clients/GitHub/src/Internal/Operator/CodeScanning/DeleteCodeqlDatabase.php b/clients/GitHub/src/Internal/Operator/CodeScanning/DeleteCodeqlDatabase.php index 43dd348d062..88cac9f7b5a 100644 --- a/clients/GitHub/src/Internal/Operator/CodeScanning/DeleteCodeqlDatabase.php +++ b/clients/GitHub/src/Internal/Operator/CodeScanning/DeleteCodeqlDatabase.php @@ -24,6 +24,7 @@ public function __construct(private Browser $browser, private AuthenticationInte { } + /** @return */ public function call(string $owner, string $repo, string $language): WithoutBody { $operation = new \ApiClients\Client\GitHub\Internal\Operation\CodeScanning\DeleteCodeqlDatabase($this->responseSchemaValidator, $this->hydrator, $owner, $repo, $language); diff --git a/clients/GitHub/src/Internal/Operator/Orgs/ListWebhookDeliveries.php b/clients/GitHub/src/Internal/Operator/Orgs/ListWebhookDeliveries.php index 2143bb69715..2497ea0a905 100644 --- a/clients/GitHub/src/Internal/Operator/Orgs/ListWebhookDeliveries.php +++ b/clients/GitHub/src/Internal/Operator/Orgs/ListWebhookDeliveries.php @@ -24,10 +24,10 @@ public function __construct(private Browser $browser, private AuthenticationInte { } - /** @return Observable */ - public function call(string $org, int $hookId, string $cursor, bool $redelivery, int $perPage = 30): iterable + /** @return iterable */ + public function call(string $org, int $hookId, string $cursor, int $perPage = 30): iterable { - $operation = new \ApiClients\Client\GitHub\Internal\Operation\Orgs\ListWebhookDeliveries($this->responseSchemaValidator, $this->hydrator, $org, $hookId, $cursor, $redelivery, $perPage); + $operation = new \ApiClients\Client\GitHub\Internal\Operation\Orgs\ListWebhookDeliveries($this->responseSchemaValidator, $this->hydrator, $org, $hookId, $cursor, $perPage); $request = $operation->createRequest(); $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { return $operation->createResponse($response); diff --git a/clients/GitHub/src/Internal/Operator/Repos/ListWebhookDeliveries.php b/clients/GitHub/src/Internal/Operator/Repos/ListWebhookDeliveries.php index ea08b0ae20c..dc402e5ced0 100644 --- a/clients/GitHub/src/Internal/Operator/Repos/ListWebhookDeliveries.php +++ b/clients/GitHub/src/Internal/Operator/Repos/ListWebhookDeliveries.php @@ -24,10 +24,10 @@ public function __construct(private Browser $browser, private AuthenticationInte { } - /** @return Observable */ - public function call(string $owner, string $repo, int $hookId, string $cursor, bool $redelivery, int $perPage = 30): iterable + /** @return iterable */ + public function call(string $owner, string $repo, int $hookId, string $cursor, int $perPage = 30): iterable { - $operation = new \ApiClients\Client\GitHub\Internal\Operation\Repos\ListWebhookDeliveries($this->responseSchemaValidator, $this->hydrator, $owner, $repo, $hookId, $cursor, $redelivery, $perPage); + $operation = new \ApiClients\Client\GitHub\Internal\Operation\Repos\ListWebhookDeliveries($this->responseSchemaValidator, $this->hydrator, $owner, $repo, $hookId, $cursor, $perPage); $request = $operation->createRequest(); $result = await($this->browser->request($request->getMethod(), (string) $request->getUri(), $request->withHeader('Authorization', $this->authentication->authHeader())->getHeaders(), (string) $request->getBody())->then(static function (ResponseInterface $response) use ($operation): Observable { return $operation->createResponse($response); diff --git a/clients/GitHub/src/Internal/Operators.php b/clients/GitHub/src/Internal/Operators.php index ed2709c4ad2..a60d8ffbe8a 100644 --- a/clients/GitHub/src/Internal/Operators.php +++ b/clients/GitHub/src/Internal/Operators.php @@ -250,6 +250,18 @@ final class Operators private Internal\Operator\Orgs\GetWebhookDelivery|null $orgs👷GetWebhookDelivery = null; private Internal\Operator\Orgs\RedeliverWebhookDelivery|null $orgs👷RedeliverWebhookDelivery = null; private Internal\Operator\Orgs\PingWebhook|null $orgs👷PingWebhook = null; + private Internal\Operator\ApiInsights\GetRouteStatsByActor|null $apiInsights👷GetRouteStatsByActor = null; + private Internal\Operator\ApiInsights\GetRouteStatsByActorListing|null $apiInsights👷GetRouteStatsByActorListing = null; + private Internal\Operator\ApiInsights\GetSubjectStats|null $apiInsights👷GetSubjectStats = null; + private Internal\Operator\ApiInsights\GetSubjectStatsListing|null $apiInsights👷GetSubjectStatsListing = null; + private Internal\Operator\ApiInsights\GetSummaryStats|null $apiInsights👷GetSummaryStats = null; + private Internal\Operator\ApiInsights\GetSummaryStatsByUser|null $apiInsights👷GetSummaryStatsByUser = null; + private Internal\Operator\ApiInsights\GetSummaryStatsByActor|null $apiInsights👷GetSummaryStatsByActor = null; + private Internal\Operator\ApiInsights\GetTimeStats|null $apiInsights👷GetTimeStats = null; + private Internal\Operator\ApiInsights\GetTimeStatsByUser|null $apiInsights👷GetTimeStatsByUser = null; + private Internal\Operator\ApiInsights\GetTimeStatsByActor|null $apiInsights👷GetTimeStatsByActor = null; + private Internal\Operator\ApiInsights\GetUserStats|null $apiInsights👷GetUserStats = null; + private Internal\Operator\ApiInsights\GetUserStatsListing|null $apiInsights👷GetUserStatsListing = null; private Internal\Operator\Apps\GetOrgInstallation|null $apps👷GetOrgInstallation = null; private Internal\Operator\Orgs\ListAppInstallations|null $orgs👷ListAppInstallations = null; private Internal\Operator\Interactions\GetRestrictionsForOrg|null $interactions👷GetRestrictionsForOrg = null; @@ -3317,6 +3329,114 @@ public function orgs👷PingWebhook(): Internal\Operator\Orgs\PingWebhook return $this->orgs👷PingWebhook; } + public function apiInsights👷GetRouteStatsByActor(): Internal\Operator\ApiInsights\GetRouteStatsByActor + { + if ($this->apiInsights👷GetRouteStatsByActor instanceof Internal\Operator\ApiInsights\GetRouteStatsByActor === false) { + $this->apiInsights👷GetRouteStatsByActor = new Internal\Operator\ApiInsights\GetRouteStatsByActor($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId()); + } + + return $this->apiInsights👷GetRouteStatsByActor; + } + + public function apiInsights👷GetRouteStatsByActorListing(): Internal\Operator\ApiInsights\GetRouteStatsByActorListing + { + if ($this->apiInsights👷GetRouteStatsByActorListing instanceof Internal\Operator\ApiInsights\GetRouteStatsByActorListing === false) { + $this->apiInsights👷GetRouteStatsByActorListing = new Internal\Operator\ApiInsights\GetRouteStatsByActorListing($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId()); + } + + return $this->apiInsights👷GetRouteStatsByActorListing; + } + + public function apiInsights👷GetSubjectStats(): Internal\Operator\ApiInsights\GetSubjectStats + { + if ($this->apiInsights👷GetSubjectStats instanceof Internal\Operator\ApiInsights\GetSubjectStats === false) { + $this->apiInsights👷GetSubjectStats = new Internal\Operator\ApiInsights\GetSubjectStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats()); + } + + return $this->apiInsights👷GetSubjectStats; + } + + public function apiInsights👷GetSubjectStatsListing(): Internal\Operator\ApiInsights\GetSubjectStatsListing + { + if ($this->apiInsights👷GetSubjectStatsListing instanceof Internal\Operator\ApiInsights\GetSubjectStatsListing === false) { + $this->apiInsights👷GetSubjectStatsListing = new Internal\Operator\ApiInsights\GetSubjectStatsListing($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats()); + } + + return $this->apiInsights👷GetSubjectStatsListing; + } + + public function apiInsights👷GetSummaryStats(): Internal\Operator\ApiInsights\GetSummaryStats + { + if ($this->apiInsights👷GetSummaryStats instanceof Internal\Operator\ApiInsights\GetSummaryStats === false) { + $this->apiInsights👷GetSummaryStats = new Internal\Operator\ApiInsights\GetSummaryStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats()); + } + + return $this->apiInsights👷GetSummaryStats; + } + + public function apiInsights👷GetSummaryStatsByUser(): Internal\Operator\ApiInsights\GetSummaryStatsByUser + { + if ($this->apiInsights👷GetSummaryStatsByUser instanceof Internal\Operator\ApiInsights\GetSummaryStatsByUser === false) { + $this->apiInsights👷GetSummaryStatsByUser = new Internal\Operator\ApiInsights\GetSummaryStatsByUser($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀Users🌀UserId()); + } + + return $this->apiInsights👷GetSummaryStatsByUser; + } + + public function apiInsights👷GetSummaryStatsByActor(): Internal\Operator\ApiInsights\GetSummaryStatsByActor + { + if ($this->apiInsights👷GetSummaryStatsByActor instanceof Internal\Operator\ApiInsights\GetSummaryStatsByActor === false) { + $this->apiInsights👷GetSummaryStatsByActor = new Internal\Operator\ApiInsights\GetSummaryStatsByActor($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀ActorType🌀ActorId()); + } + + return $this->apiInsights👷GetSummaryStatsByActor; + } + + public function apiInsights👷GetTimeStats(): Internal\Operator\ApiInsights\GetTimeStats + { + if ($this->apiInsights👷GetTimeStats instanceof Internal\Operator\ApiInsights\GetTimeStats === false) { + $this->apiInsights👷GetTimeStats = new Internal\Operator\ApiInsights\GetTimeStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats()); + } + + return $this->apiInsights👷GetTimeStats; + } + + public function apiInsights👷GetTimeStatsByUser(): Internal\Operator\ApiInsights\GetTimeStatsByUser + { + if ($this->apiInsights👷GetTimeStatsByUser instanceof Internal\Operator\ApiInsights\GetTimeStatsByUser === false) { + $this->apiInsights👷GetTimeStatsByUser = new Internal\Operator\ApiInsights\GetTimeStatsByUser($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀Users🌀UserId()); + } + + return $this->apiInsights👷GetTimeStatsByUser; + } + + public function apiInsights👷GetTimeStatsByActor(): Internal\Operator\ApiInsights\GetTimeStatsByActor + { + if ($this->apiInsights👷GetTimeStatsByActor instanceof Internal\Operator\ApiInsights\GetTimeStatsByActor === false) { + $this->apiInsights👷GetTimeStatsByActor = new Internal\Operator\ApiInsights\GetTimeStatsByActor($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀ActorType🌀ActorId()); + } + + return $this->apiInsights👷GetTimeStatsByActor; + } + + public function apiInsights👷GetUserStats(): Internal\Operator\ApiInsights\GetUserStats + { + if ($this->apiInsights👷GetUserStats instanceof Internal\Operator\ApiInsights\GetUserStats === false) { + $this->apiInsights👷GetUserStats = new Internal\Operator\ApiInsights\GetUserStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId()); + } + + return $this->apiInsights👷GetUserStats; + } + + public function apiInsights👷GetUserStatsListing(): Internal\Operator\ApiInsights\GetUserStatsListing + { + if ($this->apiInsights👷GetUserStatsListing instanceof Internal\Operator\ApiInsights\GetUserStatsListing === false) { + $this->apiInsights👷GetUserStatsListing = new Internal\Operator\ApiInsights\GetUserStatsListing($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId()); + } + + return $this->apiInsights👷GetUserStatsListing; + } + public function apps👷GetOrgInstallation(): Internal\Operator\Apps\GetOrgInstallation { if ($this->apps👷GetOrgInstallation instanceof Internal\Operator\Apps\GetOrgInstallation === false) { diff --git a/clients/GitHub/src/Internal/Router/Delete/CodeScanning.php b/clients/GitHub/src/Internal/Router/Delete/CodeScanning.php index 94897dbe137..4306142c7c5 100644 --- a/clients/GitHub/src/Internal/Router/Delete/CodeScanning.php +++ b/clients/GitHub/src/Internal/Router/Delete/CodeScanning.php @@ -53,6 +53,7 @@ public function deleteAnalysis(array $params): CodeScanningAnalysisDeletion return $operator->call($arguments['owner'], $arguments['repo'], $arguments['analysis_id'], $arguments['confirm_delete']); } + /** @return */ public function deleteCodeqlDatabase(array $params): WithoutBody { $arguments = []; diff --git a/clients/GitHub/src/Internal/Router/Delete/Eight.php b/clients/GitHub/src/Internal/Router/Delete/Eight.php index 8dc1d6a2630..0d8f1f7b474 100644 --- a/clients/GitHub/src/Internal/Router/Delete/Eight.php +++ b/clients/GitHub/src/Internal/Router/Delete/Eight.php @@ -18,7 +18,7 @@ public function __construct(private Routers $routers) { } - /** @return |\ApiClients\Tools\OpenApiClient\Utils\Response\WithoutBody|Observable|Schema\BasicError */ + /** @return |Observable|Schema\BasicError */ public function call(string $call, array $params, array $pathChunks): WithoutBody|Ok|Json|iterable|BasicError|PullRequestReview { if ($pathChunks[0] === '') { diff --git a/clients/GitHub/src/Internal/Router/Get/ApiInsights.php b/clients/GitHub/src/Internal/Router/Get/ApiInsights.php new file mode 100644 index 00000000000..27718c848bd --- /dev/null +++ b/clients/GitHub/src/Internal/Router/Get/ApiInsights.php @@ -0,0 +1,406 @@ + */ + public function getSubjectStats(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('sort', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: sort'); + } + + $arguments['sort'] = $params['sort']; + unset($params['sort']); + if (array_key_exists('page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: page'); + } + + $arguments['page'] = $params['page']; + unset($params['page']); + if (array_key_exists('per_page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: per_page'); + } + + $arguments['per_page'] = $params['per_page']; + unset($params['per_page']); + if (array_key_exists('direction', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: direction'); + } + + $arguments['direction'] = $params['direction']; + unset($params['direction']); + $operator = new Internal\Operator\ApiInsights\GetSubjectStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats()); + + return $operator->call($arguments['org'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['sort'], $arguments['page'], $arguments['per_page'], $arguments['direction']); + } + + public function getSummaryStats(array $params): ApiInsightsSummaryStats + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + $operator = new Internal\Operator\ApiInsights\GetSummaryStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats()); + + return $operator->call($arguments['org'], $arguments['min_timestamp'], $arguments['max_timestamp']); + } + + /** @return iterable */ + public function getTimeStats(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('timestamp_increment', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: timestamp_increment'); + } + + $arguments['timestamp_increment'] = $params['timestamp_increment']; + unset($params['timestamp_increment']); + $operator = new Internal\Operator\ApiInsights\GetTimeStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats()); + + return $operator->call($arguments['org'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['timestamp_increment']); + } + + /** @return iterable */ + public function getUserStats(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('user_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: user_id'); + } + + $arguments['user_id'] = $params['user_id']; + unset($params['user_id']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('sort', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: sort'); + } + + $arguments['sort'] = $params['sort']; + unset($params['sort']); + if (array_key_exists('page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: page'); + } + + $arguments['page'] = $params['page']; + unset($params['page']); + if (array_key_exists('per_page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: per_page'); + } + + $arguments['per_page'] = $params['per_page']; + unset($params['per_page']); + if (array_key_exists('direction', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: direction'); + } + + $arguments['direction'] = $params['direction']; + unset($params['direction']); + $operator = new Internal\Operator\ApiInsights\GetUserStats($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId()); + + return $operator->call($arguments['org'], $arguments['user_id'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['sort'], $arguments['page'], $arguments['per_page'], $arguments['direction']); + } + + /** @return iterable */ + public function getRouteStatsByActor(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('actor_type', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_type'); + } + + $arguments['actor_type'] = $params['actor_type']; + unset($params['actor_type']); + if (array_key_exists('actor_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_id'); + } + + $arguments['actor_id'] = $params['actor_id']; + unset($params['actor_id']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('sort', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: sort'); + } + + $arguments['sort'] = $params['sort']; + unset($params['sort']); + if (array_key_exists('page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: page'); + } + + $arguments['page'] = $params['page']; + unset($params['page']); + if (array_key_exists('per_page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: per_page'); + } + + $arguments['per_page'] = $params['per_page']; + unset($params['per_page']); + if (array_key_exists('direction', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: direction'); + } + + $arguments['direction'] = $params['direction']; + unset($params['direction']); + $operator = new Internal\Operator\ApiInsights\GetRouteStatsByActor($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId()); + + return $operator->call($arguments['org'], $arguments['actor_type'], $arguments['actor_id'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['sort'], $arguments['page'], $arguments['per_page'], $arguments['direction']); + } + + public function getSummaryStatsByUser(array $params): ApiInsightsSummaryStats + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('user_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: user_id'); + } + + $arguments['user_id'] = $params['user_id']; + unset($params['user_id']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + $operator = new Internal\Operator\ApiInsights\GetSummaryStatsByUser($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀Users🌀UserId()); + + return $operator->call($arguments['org'], $arguments['user_id'], $arguments['min_timestamp'], $arguments['max_timestamp']); + } + + public function getSummaryStatsByActor(array $params): ApiInsightsSummaryStats + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('actor_type', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_type'); + } + + $arguments['actor_type'] = $params['actor_type']; + unset($params['actor_type']); + if (array_key_exists('actor_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_id'); + } + + $arguments['actor_id'] = $params['actor_id']; + unset($params['actor_id']); + $operator = new Internal\Operator\ApiInsights\GetSummaryStatsByActor($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SummaryStats🌀ActorType🌀ActorId()); + + return $operator->call($arguments['org'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['actor_type'], $arguments['actor_id']); + } + + /** @return iterable */ + public function getTimeStatsByUser(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('user_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: user_id'); + } + + $arguments['user_id'] = $params['user_id']; + unset($params['user_id']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('timestamp_increment', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: timestamp_increment'); + } + + $arguments['timestamp_increment'] = $params['timestamp_increment']; + unset($params['timestamp_increment']); + $operator = new Internal\Operator\ApiInsights\GetTimeStatsByUser($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀Users🌀UserId()); + + return $operator->call($arguments['org'], $arguments['user_id'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['timestamp_increment']); + } + + /** @return iterable */ + public function getTimeStatsByActor(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('actor_type', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_type'); + } + + $arguments['actor_type'] = $params['actor_type']; + unset($params['actor_type']); + if (array_key_exists('actor_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_id'); + } + + $arguments['actor_id'] = $params['actor_id']; + unset($params['actor_id']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('timestamp_increment', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: timestamp_increment'); + } + + $arguments['timestamp_increment'] = $params['timestamp_increment']; + unset($params['timestamp_increment']); + $operator = new Internal\Operator\ApiInsights\GetTimeStatsByActor($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀TimeStats🌀ActorType🌀ActorId()); + + return $operator->call($arguments['org'], $arguments['actor_type'], $arguments['actor_id'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['timestamp_increment']); + } +} diff --git a/clients/GitHub/src/Internal/Router/Get/Apps.php b/clients/GitHub/src/Internal/Router/Get/Apps.php index 46d381fafc8..87911d4fd36 100644 --- a/clients/GitHub/src/Internal/Router/Get/Apps.php +++ b/clients/GitHub/src/Internal/Router/Get/Apps.php @@ -197,7 +197,7 @@ public function getWebhookConfigForApp(array $params): WebhookConfig return $operator->call(); } - /** @return Observable */ + /** @return iterable */ public function listWebhookDeliveries(array $params): iterable { $arguments = []; @@ -207,12 +207,6 @@ public function listWebhookDeliveries(array $params): iterable $arguments['cursor'] = $params['cursor']; unset($params['cursor']); - if (array_key_exists('redelivery', $params) === false) { - throw new InvalidArgumentException('Missing mandatory field: redelivery'); - } - - $arguments['redelivery'] = $params['redelivery']; - unset($params['redelivery']); if (array_key_exists('per_page', $params) === false) { throw new InvalidArgumentException('Missing mandatory field: per_page'); } @@ -221,7 +215,7 @@ public function listWebhookDeliveries(array $params): iterable unset($params['per_page']); $operator = new Internal\Operator\Apps\ListWebhookDeliveries($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀App🌀Hook🌀Deliveries()); - return $operator->call($arguments['cursor'], $arguments['redelivery'], $arguments['per_page']); + return $operator->call($arguments['cursor'], $arguments['per_page']); } /** @return */ diff --git a/clients/GitHub/src/Internal/Router/Get/Eight.php b/clients/GitHub/src/Internal/Router/Get/Eight.php index 830ad5893a6..a627e6d28fc 100644 --- a/clients/GitHub/src/Internal/Router/Get/Eight.php +++ b/clients/GitHub/src/Internal/Router/Get/Eight.php @@ -8,6 +8,7 @@ use ApiClients\Client\GitHub\Schema\ActionsPublicKey; use ApiClients\Client\GitHub\Schema\ActionsSecret; use ApiClients\Client\GitHub\Schema\ActionsVariable; +use ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats; use ApiClients\Client\GitHub\Schema\BranchRestrictionPolicy; use ApiClients\Client\GitHub\Schema\CodeScanningCodeqlDatabase; use ApiClients\Client\GitHub\Schema\CodeScanningVariantAnalysis; @@ -35,13 +36,53 @@ public function __construct(private Routers $routers) { } - /** @return |Observable|Observable|Observable|Observable|Observable|Observable|WithoutBody */ - public function call(string $call, array $params, array $pathChunks): PackageVersion|iterable|TeamRepository|WithoutBody|OidcCustomSubRepo|Ok|Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRun\Response\ApplicationJson\Ok\Application\Json|WorkflowRunUsage|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRuns\Response\ApplicationJson\Ok\Application\Json|WorkflowUsage|ProtectedBranchAdminEnforced|ProtectedBranchPullRequestReview|StatusCheckPolicy|BranchRestrictionPolicy|CodeScanningCodeqlDatabase|CodeScanningVariantAnalysis|DeploymentStatus|DeploymentBranchPolicy|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListCustomDeploymentRuleIntegrations\Response\ApplicationJson\Ok|DeploymentProtectionRule|ActionsPublicKey|ActionsSecret|ActionsVariable|HookDelivery|PullRequestReview + /** @return iterable|Schema\ApiInsightsSummaryStats|iterable||Observable|Observable|Observable|Observable|Observable|Observable|WithoutBody */ + public function call(string $call, array $params, array $pathChunks): iterable|ApiInsightsSummaryStats|PackageVersion|TeamRepository|WithoutBody|OidcCustomSubRepo|Ok|Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListJobsForWorkflowRun\Response\ApplicationJson\Ok\Application\Json|WorkflowRunUsage|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListWorkflowRuns\Response\ApplicationJson\Ok\Application\Json|WorkflowUsage|ProtectedBranchAdminEnforced|ProtectedBranchPullRequestReview|StatusCheckPolicy|BranchRestrictionPolicy|CodeScanningCodeqlDatabase|CodeScanningVariantAnalysis|DeploymentStatus|DeploymentBranchPolicy|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListCustomDeploymentRuleIntegrations\Response\ApplicationJson\Ok|DeploymentProtectionRule|ActionsPublicKey|ActionsSecret|ActionsVariable|HookDelivery|PullRequestReview { if ($pathChunks[0] === '') { if ($pathChunks[1] === 'orgs') { if ($pathChunks[2] === '{org}') { - if ($pathChunks[3] === 'packages') { + if ($pathChunks[3] === 'insights') { + if ($pathChunks[4] === 'api') { + if ($pathChunks[5] === 'route-stats') { + if ($pathChunks[6] === '{actor_type}') { + if ($pathChunks[7] === '{actor_id}') { + if ($call === 'GET /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getRouteStatsByActor($params); + } + } + } + } elseif ($pathChunks[5] === 'summary-stats') { + if ($pathChunks[6] === 'users') { + if ($pathChunks[7] === '{user_id}') { + if ($call === 'GET /orgs/{org}/insights/api/summary-stats/users/{user_id}') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getSummaryStatsByUser($params); + } + } + } elseif ($pathChunks[6] === '{actor_type}') { + if ($pathChunks[7] === '{actor_id}') { + if ($call === 'GET /orgs/{org}/insights/api/summary-stats/{actor_type}/{actor_id}') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getSummaryStatsByActor($params); + } + } + } + } elseif ($pathChunks[5] === 'time-stats') { + if ($pathChunks[6] === 'users') { + if ($pathChunks[7] === '{user_id}') { + if ($call === 'GET /orgs/{org}/insights/api/time-stats/users/{user_id}') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getTimeStatsByUser($params); + } + } + } elseif ($pathChunks[6] === '{actor_type}') { + if ($pathChunks[7] === '{actor_id}') { + if ($call === 'GET /orgs/{org}/insights/api/time-stats/{actor_type}/{actor_id}') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getTimeStatsByActor($params); + } + } + } + } + } + } elseif ($pathChunks[3] === 'packages') { if ($pathChunks[4] === '{package_type}') { if ($pathChunks[5] === '{package_name}') { if ($pathChunks[6] === 'versions') { diff --git a/clients/GitHub/src/Internal/Router/Get/Four.php b/clients/GitHub/src/Internal/Router/Get/Four.php index 7c40facd4ed..39800ca6f31 100644 --- a/clients/GitHub/src/Internal/Router/Get/Four.php +++ b/clients/GitHub/src/Internal/Router/Get/Four.php @@ -34,7 +34,7 @@ public function __construct(private Routers $routers) { } - /** @return |Observable|Observable|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|Observable|Observable|Observable|Observable|Observable|Observable|Observable */ + /** @return |iterable|Observable|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|Observable|Observable|Observable|Observable|Observable|Observable|Observable */ public function call(string $call, array $params, array $pathChunks): WebhookConfig|iterable|Installation|WithoutBody|GistSimple|GitignoreTemplate|MarketplacePurchase|Thread|Ok|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListAppInstallations\Response\ApplicationJson\Ok|InteractionLimitResponse|One|\ApiClients\Client\GitHub\Schema\Operations\Orgs\ListOrgRoles\Response\ApplicationJson\Ok|ProjectColumn|FullRepository|BasicError|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSecretsForAuthenticatedUser\Response\ApplicationJson\Ok|Codespace|GpgKey|Key|Migration|SshSigningKey|Hovercard|StarredRepository|Repository { if ($pathChunks[0] === '') { diff --git a/clients/GitHub/src/Internal/Router/Get/Orgs.php b/clients/GitHub/src/Internal/Router/Get/Orgs.php index c2558871da8..f5bc78a4dad 100644 --- a/clients/GitHub/src/Internal/Router/Get/Orgs.php +++ b/clients/GitHub/src/Internal/Router/Get/Orgs.php @@ -802,7 +802,7 @@ public function getWebhookConfigForOrg(array $params): WebhookConfig return $operator->call($arguments['org'], $arguments['hook_id']); } - /** @return Observable */ + /** @return iterable */ public function listWebhookDeliveries(array $params): iterable { $arguments = []; @@ -824,12 +824,6 @@ public function listWebhookDeliveries(array $params): iterable $arguments['cursor'] = $params['cursor']; unset($params['cursor']); - if (array_key_exists('redelivery', $params) === false) { - throw new InvalidArgumentException('Missing mandatory field: redelivery'); - } - - $arguments['redelivery'] = $params['redelivery']; - unset($params['redelivery']); if (array_key_exists('per_page', $params) === false) { throw new InvalidArgumentException('Missing mandatory field: per_page'); } @@ -838,7 +832,7 @@ public function listWebhookDeliveries(array $params): iterable unset($params['per_page']); $operator = new Internal\Operator\Orgs\ListWebhookDeliveries($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Hooks🌀HookId🌀Deliveries()); - return $operator->call($arguments['org'], $arguments['hook_id'], $arguments['cursor'], $arguments['redelivery'], $arguments['per_page']); + return $operator->call($arguments['org'], $arguments['hook_id'], $arguments['cursor'], $arguments['per_page']); } /** @return Observable */ diff --git a/clients/GitHub/src/Internal/Router/Get/Repos.php b/clients/GitHub/src/Internal/Router/Get/Repos.php index 00feb112c83..51ba75e6516 100644 --- a/clients/GitHub/src/Internal/Router/Get/Repos.php +++ b/clients/GitHub/src/Internal/Router/Get/Repos.php @@ -2529,7 +2529,7 @@ public function getWebhookConfigForRepo(array $params): WebhookConfig return $operator->call($arguments['owner'], $arguments['repo'], $arguments['hook_id']); } - /** @return Observable */ + /** @return iterable */ public function listWebhookDeliveries(array $params): iterable { $arguments = []; @@ -2557,12 +2557,6 @@ public function listWebhookDeliveries(array $params): iterable $arguments['cursor'] = $params['cursor']; unset($params['cursor']); - if (array_key_exists('redelivery', $params) === false) { - throw new InvalidArgumentException('Missing mandatory field: redelivery'); - } - - $arguments['redelivery'] = $params['redelivery']; - unset($params['redelivery']); if (array_key_exists('per_page', $params) === false) { throw new InvalidArgumentException('Missing mandatory field: per_page'); } @@ -2571,7 +2565,7 @@ public function listWebhookDeliveries(array $params): iterable unset($params['per_page']); $operator = new Internal\Operator\Repos\ListWebhookDeliveries($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Hooks🌀HookId🌀Deliveries()); - return $operator->call($arguments['owner'], $arguments['repo'], $arguments['hook_id'], $arguments['cursor'], $arguments['redelivery'], $arguments['per_page']); + return $operator->call($arguments['owner'], $arguments['repo'], $arguments['hook_id'], $arguments['cursor'], $arguments['per_page']); } /** @return */ diff --git a/clients/GitHub/src/Internal/Router/Get/Seven.php b/clients/GitHub/src/Internal/Router/Get/Seven.php index 08b0b4d1404..f186e6bde2a 100644 --- a/clients/GitHub/src/Internal/Router/Get/Seven.php +++ b/clients/GitHub/src/Internal/Router/Get/Seven.php @@ -63,7 +63,7 @@ public function __construct(private Routers $routers) { } - /** @return Observable|Observable||Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Schema\BasicError|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Schema\ConvertedNoteToIssueIssueEvent|Schema\TimelineCommentEvent|Schema\TimelineCrossReferencedEvent|Schema\TimelineCommittedEvent|Schema\TimelineReviewedEvent|Schema\TimelineLineCommentedEvent|Schema\TimelineCommitCommentedEvent|Schema\TimelineAssignedIssueEvent|Schema\TimelineUnassignedIssueEvent|Schema\StateChangeIssueEvent>|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable */ + /** @return Observable|Observable||Observable|iterable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Schema\BasicError|Observable|Observable|Observable|iterable|Observable|Observable|Observable|Schema\ConvertedNoteToIssueIssueEvent|Schema\TimelineCommentEvent|Schema\TimelineCrossReferencedEvent|Schema\TimelineCommittedEvent|Schema\TimelineReviewedEvent|Schema\TimelineLineCommentedEvent|Schema\TimelineCommitCommentedEvent|Schema\TimelineAssignedIssueEvent|Schema\TimelineUnassignedIssueEvent|Schema\StateChangeIssueEvent>|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable */ public function call(string $call, array $params, array $pathChunks): iterable|OidcCustomSub|Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelfHostedRunnersInGroupForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListLabelsForSelfHostedRunnerForOrg\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok|Json|WithoutBody|\ApiClients\Client\GitHub\Schema\Operations\Codespaces\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Dependabot\ListSelectedReposForOrgSecret\Response\ApplicationJson\Ok\Application\Json|HookDelivery|TeamDiscussion|TeamMembership|TeamProject|Artifact|ActionsCacheUsageByRepository|Job|ActionsWorkflowAccessToRepository|SelectedActions|ActionsGetDefaultWorkflowPermissions|Runner|WorkflowRun|ActionsPublicKey|ActionsSecret|ActionsVariable|Workflow|BranchProtection|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForSuite\Response\ApplicationJson\Ok|CodeScanningAlert|CodeScanningAnalysis|CodeScanningSarifsStatus|CodespacesPublicKey|RepoCodespacesSecret|RepositoryCollaboratorPermission|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListForRef\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Checks\ListSuitesForRef\Response\ApplicationJson\Ok|CombinedCommitStatus|BasicError|DependabotAlert|DependabotPublicKey|DependabotSecret|\ApiClients\Client\GitHub\Schema\Operations\Repos\ListDeploymentBranchPolicies\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Repos\GetAllDeploymentProtectionRules\Response\ApplicationJson\Ok|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentSecrets\Response\ApplicationJson\Ok\Application\Json|\ApiClients\Client\GitHub\Schema\Operations\Actions\ListEnvironmentVariables\Response\ApplicationJson\Ok\Application\Json|Blob|GitCommit|GitRef|GitTag|GitTree|WebhookConfig|IssueComment|IssueEvent|PageBuild|PagesDeploymentStatus|PullRequestReviewComment|PullRequestReviewRequest|ReleaseAsset|Release|RuleSuite|SecretScanningAlert|TeamDiscussionComment|PackageVersion { if ($pathChunks[0] === '') { @@ -173,6 +173,16 @@ public function call(string $call, array $params, array $pathChunks): iterable|O } } } + } elseif ($pathChunks[3] === 'insights') { + if ($pathChunks[4] === 'api') { + if ($pathChunks[5] === 'user-stats') { + if ($pathChunks[6] === '{user_id}') { + if ($call === 'GET /orgs/{org}/insights/api/user-stats/{user_id}') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getUserStats($params); + } + } + } + } } elseif ($pathChunks[3] === 'packages') { if ($pathChunks[4] === '{package_type}') { if ($pathChunks[5] === '{package_name}') { diff --git a/clients/GitHub/src/Internal/Router/Get/Six.php b/clients/GitHub/src/Internal/Router/Get/Six.php index 610ebba8adc..c57c4d3860c 100644 --- a/clients/GitHub/src/Internal/Router/Get/Six.php +++ b/clients/GitHub/src/Internal/Router/Get/Six.php @@ -11,6 +11,7 @@ use ApiClients\Client\GitHub\Schema\ActionsGetDefaultWorkflowPermissions; use ApiClients\Client\GitHub\Schema\ActionsPublicKey; use ApiClients\Client\GitHub\Schema\ActionsRepositoryPermissions; +use ApiClients\Client\GitHub\Schema\ApiInsightsSummaryStats; use ApiClients\Client\GitHub\Schema\Autolink; use ApiClients\Client\GitHub\Schema\BasicError; use ApiClients\Client\GitHub\Schema\BranchWithProtection; @@ -75,8 +76,8 @@ public function __construct(private Routers $routers) { } - /** @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|RunnerGroupsOrg|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 + /** @return |Observable|Observable|Observable|WithoutBody|iterable|iterable|Schema\ApiInsightsSummaryStats|iterable|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|RunnerGroupsOrg|Runner|ActionsPublicKey|OrganizationActionsSecret|OrganizationActionsVariable|WithoutBody|CodeSecurityConfiguration|CodespacesPublicKey|CodespacesOrgSecret|\ApiClients\Client\GitHub\Schema\Operations\Copilot\ListCopilotSeats\Response\ApplicationJson\Ok|DependabotPublicKey|OrganizationDependabotSecret|WebhookConfig|ApiInsightsSummaryStats|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] === '') { if ($pathChunks[1] === 'enterprises') { @@ -219,6 +220,22 @@ public function call(string $call, array $params, array $pathChunks): Ok|iterabl } } } + } elseif ($pathChunks[3] === 'insights') { + if ($pathChunks[4] === 'api') { + if ($pathChunks[5] === 'subject-stats') { + if ($call === 'GET /orgs/{org}/insights/api/subject-stats') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getSubjectStats($params); + } + } elseif ($pathChunks[5] === 'summary-stats') { + if ($call === 'GET /orgs/{org}/insights/api/summary-stats') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getSummaryStats($params); + } + } elseif ($pathChunks[5] === 'time-stats') { + if ($call === 'GET /orgs/{org}/insights/api/time-stats') { + return $this->routers->internal🔀Router🔀Get🔀ApiInsights()->getTimeStats($params); + } + } + } } elseif ($pathChunks[3] === 'invitations') { if ($pathChunks[4] === '{invitation_id}') { if ($pathChunks[5] === 'teams') { diff --git a/clients/GitHub/src/Internal/Router/List/ApiInsights.php b/clients/GitHub/src/Internal/Router/List/ApiInsights.php new file mode 100644 index 00000000000..0fc8038500e --- /dev/null +++ b/clients/GitHub/src/Internal/Router/List/ApiInsights.php @@ -0,0 +1,211 @@ + */ + public function getUserStatsListing(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('user_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: user_id'); + } + + $arguments['user_id'] = $params['user_id']; + unset($params['user_id']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('sort', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: sort'); + } + + $arguments['sort'] = $params['sort']; + unset($params['sort']); + if (array_key_exists('page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: page'); + } + + $arguments['page'] = $params['page']; + unset($params['page']); + if (array_key_exists('per_page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: per_page'); + } + + $arguments['per_page'] = $params['per_page']; + unset($params['per_page']); + if (array_key_exists('direction', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: direction'); + } + + $arguments['direction'] = $params['direction']; + unset($params['direction']); + $arguments['page'] = 1; + do { + $operator = new Internal\Operator\ApiInsights\GetUserStatsListing($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀UserStats🌀UserId()); + $items = [...$operator->call($arguments['org'], $arguments['user_id'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['sort'], $arguments['page'], $arguments['per_page'], $arguments['direction'])]; + + yield from $items; + + $arguments['page']++; + } while (count($items) > 0); + } + + /** @return iterable */ + public function getSubjectStatsListing(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('sort', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: sort'); + } + + $arguments['sort'] = $params['sort']; + unset($params['sort']); + if (array_key_exists('page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: page'); + } + + $arguments['page'] = $params['page']; + unset($params['page']); + if (array_key_exists('per_page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: per_page'); + } + + $arguments['per_page'] = $params['per_page']; + unset($params['per_page']); + if (array_key_exists('direction', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: direction'); + } + + $arguments['direction'] = $params['direction']; + unset($params['direction']); + $arguments['page'] = 1; + do { + $operator = new Internal\Operator\ApiInsights\GetSubjectStatsListing($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀SubjectStats()); + $items = [...$operator->call($arguments['org'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['sort'], $arguments['page'], $arguments['per_page'], $arguments['direction'])]; + + yield from $items; + + $arguments['page']++; + } while (count($items) > 0); + } + + /** @return iterable */ + public function getRouteStatsByActorListing(array $params): iterable + { + $arguments = []; + if (array_key_exists('org', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: org'); + } + + $arguments['org'] = $params['org']; + unset($params['org']); + if (array_key_exists('actor_type', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_type'); + } + + $arguments['actor_type'] = $params['actor_type']; + unset($params['actor_type']); + if (array_key_exists('actor_id', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: actor_id'); + } + + $arguments['actor_id'] = $params['actor_id']; + unset($params['actor_id']); + if (array_key_exists('min_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: min_timestamp'); + } + + $arguments['min_timestamp'] = $params['min_timestamp']; + unset($params['min_timestamp']); + if (array_key_exists('max_timestamp', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: max_timestamp'); + } + + $arguments['max_timestamp'] = $params['max_timestamp']; + unset($params['max_timestamp']); + if (array_key_exists('sort', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: sort'); + } + + $arguments['sort'] = $params['sort']; + unset($params['sort']); + if (array_key_exists('page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: page'); + } + + $arguments['page'] = $params['page']; + unset($params['page']); + if (array_key_exists('per_page', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: per_page'); + } + + $arguments['per_page'] = $params['per_page']; + unset($params['per_page']); + if (array_key_exists('direction', $params) === false) { + throw new InvalidArgumentException('Missing mandatory field: direction'); + } + + $arguments['direction'] = $params['direction']; + unset($params['direction']); + $arguments['page'] = 1; + do { + $operator = new Internal\Operator\ApiInsights\GetRouteStatsByActorListing($this->browser, $this->authentication, $this->responseSchemaValidator, $this->hydrators->getObjectMapperOperation🌀Orgs🌀Org🌀Insights🌀Api🌀RouteStats🌀ActorType🌀ActorId()); + $items = [...$operator->call($arguments['org'], $arguments['actor_type'], $arguments['actor_id'], $arguments['min_timestamp'], $arguments['max_timestamp'], $arguments['sort'], $arguments['page'], $arguments['per_page'], $arguments['direction'])]; + + yield from $items; + + $arguments['page']++; + } while (count($items) > 0); + } +} diff --git a/clients/GitHub/src/Internal/Router/List/Eight.php b/clients/GitHub/src/Internal/Router/List/Eight.php index b0d21bfe73a..5843a2ee94c 100644 --- a/clients/GitHub/src/Internal/Router/List/Eight.php +++ b/clients/GitHub/src/Internal/Router/List/Eight.php @@ -15,13 +15,25 @@ public function __construct(private Routers $routers) { } - /** @return Observable|Observable|Observable|Observable|WithoutBody */ + /** @return iterable|Observable|Observable|Observable|Observable|WithoutBody */ public function call(string $call, array $params, array $pathChunks): iterable|WithoutBody { if ($pathChunks[0] === '') { if ($pathChunks[1] === 'orgs') { if ($pathChunks[2] === '{org}') { - if ($pathChunks[3] === 'teams') { + if ($pathChunks[3] === 'insights') { + if ($pathChunks[4] === 'api') { + if ($pathChunks[5] === 'route-stats') { + if ($pathChunks[6] === '{actor_type}') { + if ($pathChunks[7] === '{actor_id}') { + if ($call === 'LIST /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}') { + return $this->routers->internal🔀Router🔀List🔀ApiInsights()->getRouteStatsByActorListing($params); + } + } + } + } + } + } elseif ($pathChunks[3] === 'teams') { if ($pathChunks[4] === '{team_slug}') { if ($pathChunks[5] === 'discussions') { if ($pathChunks[6] === '{discussion_number}') { diff --git a/clients/GitHub/src/Internal/Router/List/Seven.php b/clients/GitHub/src/Internal/Router/List/Seven.php index ed7aa79b717..8077b5bec4a 100644 --- a/clients/GitHub/src/Internal/Router/List/Seven.php +++ b/clients/GitHub/src/Internal/Router/List/Seven.php @@ -14,7 +14,7 @@ public function __construct(private Routers $routers) { } - /** @return Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Schema\BasicError|Observable|Observable|Observable|Observable|Schema\ConvertedNoteToIssueIssueEvent|Schema\TimelineCommentEvent|Schema\TimelineCrossReferencedEvent|Schema\TimelineCommittedEvent|Schema\TimelineReviewedEvent|Schema\TimelineLineCommentedEvent|Schema\TimelineCommitCommentedEvent|Schema\TimelineAssignedIssueEvent|Schema\TimelineUnassignedIssueEvent|Schema\StateChangeIssueEvent>|Observable|Observable|Observable|Observable|Observable|Observable */ + /** @return Observable|Observable|iterable|Observable|Observable|Observable|Observable|Observable|Observable|Schema\BasicError|Observable|Observable|Observable|Observable|Schema\ConvertedNoteToIssueIssueEvent|Schema\TimelineCommentEvent|Schema\TimelineCrossReferencedEvent|Schema\TimelineCommittedEvent|Schema\TimelineReviewedEvent|Schema\TimelineLineCommentedEvent|Schema\TimelineCommitCommentedEvent|Schema\TimelineAssignedIssueEvent|Schema\TimelineUnassignedIssueEvent|Schema\StateChangeIssueEvent>|Observable|Observable|Observable|Observable|Observable|Observable */ public function call(string $call, array $params, array $pathChunks): iterable|BasicError { if ($pathChunks[0] === '') { @@ -38,7 +38,17 @@ public function call(string $call, array $params, array $pathChunks): iterable|B } } elseif ($pathChunks[1] === 'orgs') { if ($pathChunks[2] === '{org}') { - if ($pathChunks[3] === 'packages') { + if ($pathChunks[3] === 'insights') { + if ($pathChunks[4] === 'api') { + if ($pathChunks[5] === 'user-stats') { + if ($pathChunks[6] === '{user_id}') { + if ($call === 'LIST /orgs/{org}/insights/api/user-stats/{user_id}') { + return $this->routers->internal🔀Router🔀List🔀ApiInsights()->getUserStatsListing($params); + } + } + } + } + } elseif ($pathChunks[3] === 'packages') { if ($pathChunks[4] === '{package_type}') { if ($pathChunks[5] === '{package_name}') { if ($pathChunks[6] === 'versions') { diff --git a/clients/GitHub/src/Internal/Router/List/Six.php b/clients/GitHub/src/Internal/Router/List/Six.php index e2afcb66c84..ab1b6ca29b2 100644 --- a/clients/GitHub/src/Internal/Router/List/Six.php +++ b/clients/GitHub/src/Internal/Router/List/Six.php @@ -15,7 +15,7 @@ public function __construct(private Routers $routers) { } - /** @return Observable|Observable|Observable|Observable|WithoutBody|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable */ + /** @return Observable|iterable|Observable|Observable|Observable|WithoutBody|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable|Observable */ public function call(string $call, array $params, array $pathChunks): iterable|WithoutBody { if ($pathChunks[0] === '') { @@ -33,7 +33,15 @@ public function call(string $call, array $params, array $pathChunks): iterable|W } } elseif ($pathChunks[1] === 'orgs') { if ($pathChunks[2] === '{org}') { - if ($pathChunks[3] === 'invitations') { + if ($pathChunks[3] === 'insights') { + if ($pathChunks[4] === 'api') { + if ($pathChunks[5] === 'subject-stats') { + if ($call === 'LIST /orgs/{org}/insights/api/subject-stats') { + return $this->routers->internal🔀Router🔀List🔀ApiInsights()->getSubjectStatsListing($params); + } + } + } + } elseif ($pathChunks[3] === 'invitations') { if ($pathChunks[4] === '{invitation_id}') { if ($pathChunks[5] === 'teams') { if ($call === 'LIST /orgs/{org}/invitations/{invitation_id}/teams') { diff --git a/clients/GitHub/src/Internal/Routers.php b/clients/GitHub/src/Internal/Routers.php index 69c3aadff1b..cbdef2afaab 100644 --- a/clients/GitHub/src/Internal/Routers.php +++ b/clients/GitHub/src/Internal/Routers.php @@ -40,6 +40,7 @@ final class Routers private Internal\Router\Get\CodeScanning|null $internal🔀Router🔀Get🔀CodeScanning = null; private Internal\Router\Get\CodeSecurity|null $internal🔀Router🔀Get🔀CodeSecurity = null; private Internal\Router\Get\Pulls|null $internal🔀Router🔀Get🔀Pulls = null; + private Internal\Router\Get\ApiInsights|null $internal🔀Router🔀Get🔀ApiInsights = null; private Internal\Router\Get\Billing|null $internal🔀Router🔀Get🔀Billing = null; private Internal\Router\Get\Checks|null $internal🔀Router🔀Get🔀Checks = null; private Internal\Router\Get\DependencyGraph|null $internal🔀Router🔀Get🔀DependencyGraph = null; @@ -106,6 +107,7 @@ final class Routers private Internal\Router\List\CodeScanning|null $internal🔀Router🔀List🔀CodeScanning = null; private Internal\Router\List\SecretScanning|null $internal🔀Router🔀List🔀SecretScanning = null; private Internal\Router\List\Pulls|null $internal🔀Router🔀List🔀Pulls = null; + private Internal\Router\List\ApiInsights|null $internal🔀Router🔀List🔀ApiInsights = null; private Internal\Router\List\Checks|null $internal🔀Router🔀List🔀Checks = null; private Internal\Router\List\Reactions|null $internal🔀Router🔀List🔀Reactions = null; private Internal\Router\List\Dependabot|null $internal🔀Router🔀List🔀Dependabot = null; @@ -416,6 +418,15 @@ public function internal🔀Router🔀Get🔀Pulls(): Internal\Router\Get\Pulls return $this->internal🔀Router🔀Get🔀Pulls; } + public function internal🔀Router🔀Get🔀ApiInsights(): Internal\Router\Get\ApiInsights + { + if ($this->internal🔀Router🔀Get🔀ApiInsights instanceof Internal\Router\Get\ApiInsights === false) { + $this->internal🔀Router🔀Get🔀ApiInsights = new Internal\Router\Get\ApiInsights(browser: $this->browser, authentication: $this->authentication, requestSchemaValidator: $this->requestSchemaValidator, responseSchemaValidator: $this->responseSchemaValidator, hydrators: $this->hydrators); + } + + return $this->internal🔀Router🔀Get🔀ApiInsights; + } + public function internal🔀Router🔀Get🔀Billing(): Internal\Router\Get\Billing { if ($this->internal🔀Router🔀Get🔀Billing instanceof Internal\Router\Get\Billing === false) { @@ -1010,6 +1021,15 @@ public function internal🔀Router🔀List🔀Pulls(): Internal\Router\List\Pull return $this->internal🔀Router🔀List🔀Pulls; } + public function internal🔀Router🔀List🔀ApiInsights(): Internal\Router\List\ApiInsights + { + if ($this->internal🔀Router🔀List🔀ApiInsights instanceof Internal\Router\List\ApiInsights === false) { + $this->internal🔀Router🔀List🔀ApiInsights = new Internal\Router\List\ApiInsights(browser: $this->browser, authentication: $this->authentication, requestSchemaValidator: $this->requestSchemaValidator, responseSchemaValidator: $this->responseSchemaValidator, hydrators: $this->hydrators); + } + + return $this->internal🔀Router🔀List🔀ApiInsights; + } + public function internal🔀Router🔀List🔀Checks(): Internal\Router\List\Checks { if ($this->internal🔀Router🔀List🔀Checks instanceof Internal\Router\List\Checks === false) { diff --git a/clients/GitHub/src/Operation/ApiInsights.php b/clients/GitHub/src/Operation/ApiInsights.php new file mode 100644 index 00000000000..68ffed28f43 --- /dev/null +++ b/clients/GitHub/src/Operation/ApiInsights.php @@ -0,0 +1,85 @@ + */ + public function getRouteStatsByActor(string $org, string $actorType, int $actorId, string $minTimestamp, string $maxTimestamp, array $sort, int $page, int $perPage, string $direction): iterable + { + return $this->operators->apiInsights👷GetRouteStatsByActor()->call($org, $actorType, $actorId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + } + + /** @return iterable */ + public function getRouteStatsByActorListing(string $org, string $actorType, int $actorId, string $minTimestamp, string $maxTimestamp, array $sort, int $page, int $perPage, string $direction): iterable + { + return $this->operators->apiInsights👷GetRouteStatsByActorListing()->call($org, $actorType, $actorId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + } + + /** @return iterable */ + public function getSubjectStats(string $org, string $minTimestamp, string $maxTimestamp, array $sort, int $page, int $perPage, string $direction): iterable + { + return $this->operators->apiInsights👷GetSubjectStats()->call($org, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + } + + /** @return iterable */ + public function getSubjectStatsListing(string $org, string $minTimestamp, string $maxTimestamp, array $sort, int $page, int $perPage, string $direction): iterable + { + return $this->operators->apiInsights👷GetSubjectStatsListing()->call($org, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + } + + public function getSummaryStats(string $org, string $minTimestamp, string $maxTimestamp): ApiInsightsSummaryStats + { + return $this->operators->apiInsights👷GetSummaryStats()->call($org, $minTimestamp, $maxTimestamp); + } + + public function getSummaryStatsByUser(string $org, string $userId, string $minTimestamp, string $maxTimestamp): ApiInsightsSummaryStats + { + return $this->operators->apiInsights👷GetSummaryStatsByUser()->call($org, $userId, $minTimestamp, $maxTimestamp); + } + + public function getSummaryStatsByActor(string $org, string $minTimestamp, string $maxTimestamp, string $actorType, int $actorId): ApiInsightsSummaryStats + { + return $this->operators->apiInsights👷GetSummaryStatsByActor()->call($org, $minTimestamp, $maxTimestamp, $actorType, $actorId); + } + + /** @return iterable */ + public function getTimeStats(string $org, string $minTimestamp, string $maxTimestamp, string $timestampIncrement): iterable + { + return $this->operators->apiInsights👷GetTimeStats()->call($org, $minTimestamp, $maxTimestamp, $timestampIncrement); + } + + /** @return iterable */ + public function getTimeStatsByUser(string $org, string $userId, string $minTimestamp, string $maxTimestamp, string $timestampIncrement): iterable + { + return $this->operators->apiInsights👷GetTimeStatsByUser()->call($org, $userId, $minTimestamp, $maxTimestamp, $timestampIncrement); + } + + /** @return iterable */ + public function getTimeStatsByActor(string $org, string $actorType, int $actorId, string $minTimestamp, string $maxTimestamp, string $timestampIncrement): iterable + { + return $this->operators->apiInsights👷GetTimeStatsByActor()->call($org, $actorType, $actorId, $minTimestamp, $maxTimestamp, $timestampIncrement); + } + + /** @return iterable */ + public function getUserStats(string $org, string $userId, string $minTimestamp, string $maxTimestamp, array $sort, int $page, int $perPage, string $direction): iterable + { + return $this->operators->apiInsights👷GetUserStats()->call($org, $userId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + } + + /** @return iterable */ + public function getUserStatsListing(string $org, string $userId, string $minTimestamp, string $maxTimestamp, array $sort, int $page, int $perPage, string $direction): iterable + { + return $this->operators->apiInsights👷GetUserStatsListing()->call($org, $userId, $minTimestamp, $maxTimestamp, $sort, $page, $perPage, $direction); + } +} diff --git a/clients/GitHub/src/Operation/Apps.php b/clients/GitHub/src/Operation/Apps.php index baebf235549..c52c89e6cb2 100644 --- a/clients/GitHub/src/Operation/Apps.php +++ b/clients/GitHub/src/Operation/Apps.php @@ -48,10 +48,10 @@ public function updateWebhookConfigForApp(array $params): WebhookConfig return $this->operators->apps👷UpdateWebhookConfigForApp()->call($params); } - /** @return Observable */ - public function listWebhookDeliveries(string $cursor, bool $redelivery, int $perPage): iterable + /** @return iterable */ + public function listWebhookDeliveries(string $cursor, int $perPage): iterable { - return $this->operators->apps👷ListWebhookDeliveries()->call($cursor, $redelivery, $perPage); + return $this->operators->apps👷ListWebhookDeliveries()->call($cursor, $perPage); } /** @return */ diff --git a/clients/GitHub/src/Operation/CodeScanning.php b/clients/GitHub/src/Operation/CodeScanning.php index 7842c672c87..4786830ab4c 100644 --- a/clients/GitHub/src/Operation/CodeScanning.php +++ b/clients/GitHub/src/Operation/CodeScanning.php @@ -109,6 +109,7 @@ public function getCodeqlDatabase(string $owner, string $repo, string $language) return $this->operators->codeScanning👷GetCodeqlDatabase()->call($owner, $repo, $language); } + /** @return */ public function deleteCodeqlDatabase(string $owner, string $repo, string $language): WithoutBody { return $this->operators->codeScanning👷DeleteCodeqlDatabase()->call($owner, $repo, $language); diff --git a/clients/GitHub/src/Operation/Orgs.php b/clients/GitHub/src/Operation/Orgs.php index dc8ac3d0e64..0601e127b87 100644 --- a/clients/GitHub/src/Operation/Orgs.php +++ b/clients/GitHub/src/Operation/Orgs.php @@ -144,10 +144,10 @@ public function updateWebhookConfigForOrg(string $org, int $hookId, array $param return $this->operators->orgs👷UpdateWebhookConfigForOrg()->call($org, $hookId, $params); } - /** @return Observable */ - public function listWebhookDeliveries(string $org, int $hookId, string $cursor, bool $redelivery, int $perPage): iterable + /** @return iterable */ + public function listWebhookDeliveries(string $org, int $hookId, string $cursor, int $perPage): iterable { - return $this->operators->orgs👷ListWebhookDeliveries()->call($org, $hookId, $cursor, $redelivery, $perPage); + return $this->operators->orgs👷ListWebhookDeliveries()->call($org, $hookId, $cursor, $perPage); } /** @return */ diff --git a/clients/GitHub/src/Operation/Repos.php b/clients/GitHub/src/Operation/Repos.php index a0e1e3d4b4d..6e7b7f53e16 100644 --- a/clients/GitHub/src/Operation/Repos.php +++ b/clients/GitHub/src/Operation/Repos.php @@ -839,10 +839,10 @@ public function updateWebhookConfigForRepo(string $owner, string $repo, int $hoo return $this->operators->repos👷UpdateWebhookConfigForRepo()->call($owner, $repo, $hookId, $params); } - /** @return Observable */ - public function listWebhookDeliveries(string $owner, string $repo, int $hookId, string $cursor, bool $redelivery, int $perPage): iterable + /** @return iterable */ + public function listWebhookDeliveries(string $owner, string $repo, int $hookId, string $cursor, int $perPage): iterable { - return $this->operators->repos👷ListWebhookDeliveries()->call($owner, $repo, $hookId, $cursor, $redelivery, $perPage); + return $this->operators->repos👷ListWebhookDeliveries()->call($owner, $repo, $hookId, $cursor, $perPage); } /** @return */ diff --git a/clients/GitHub/src/Operations.php b/clients/GitHub/src/Operations.php index b6f2c18030e..5e7ba7baa03 100644 --- a/clients/GitHub/src/Operations.php +++ b/clients/GitHub/src/Operations.php @@ -120,6 +120,11 @@ public function packages(): Operation\Packages return new Operation\Packages($this->operators); } + public function apiInsights(): Operation\ApiInsights + { + return new Operation\ApiInsights($this->operators); + } + public function interactions(): Operation\Interactions { return new Operation\Interactions($this->operators); diff --git a/clients/GitHub/src/OperationsInterface.php b/clients/GitHub/src/OperationsInterface.php index 3b96cbb59d0..aa83aaa55eb 100644 --- a/clients/GitHub/src/OperationsInterface.php +++ b/clients/GitHub/src/OperationsInterface.php @@ -50,6 +50,8 @@ public function codespaces(): Operation\Codespaces; public function packages(): Operation\Packages; + public function apiInsights(): Operation\ApiInsights; + public function interactions(): Operation\Interactions; public function migrations(): Operation\Migrations; diff --git a/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php b/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php index 3e3300fb39d..db44b618544 100644 --- a/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php +++ b/clients/GitHub/src/PHPStan/ClientCallReturnTypes.php @@ -72,7 +72,7 @@ public function getTypeFromMethodCall(MethodReflection $methodReflection, Method } if ($call === 'GET /app/hook/deliveries') { - return $this->typeResolver->resolve('Observable'); + return $this->typeResolver->resolve('iterable'); } if ($call === 'GET /app/hook/deliveries/{delivery_id}') { @@ -984,7 +984,7 @@ public function getTypeFromMethodCall(MethodReflection $methodReflection, Method } if ($call === 'GET /orgs/{org}/hooks/{hook_id}/deliveries') { - return $this->typeResolver->resolve('Observable'); + return $this->typeResolver->resolve('iterable'); } if ($call === 'GET /orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}') { @@ -999,6 +999,54 @@ public function getTypeFromMethodCall(MethodReflection $methodReflection, Method return $this->typeResolver->resolve(''); } + if ($call === 'GET /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'LIST /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'GET /orgs/{org}/insights/api/subject-stats') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'LIST /orgs/{org}/insights/api/subject-stats') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'GET /orgs/{org}/insights/api/summary-stats') { + return $this->typeResolver->resolve('Schema\\ApiInsightsSummaryStats'); + } + + if ($call === 'GET /orgs/{org}/insights/api/summary-stats/users/{user_id}') { + return $this->typeResolver->resolve('Schema\\ApiInsightsSummaryStats'); + } + + if ($call === 'GET /orgs/{org}/insights/api/summary-stats/{actor_type}/{actor_id}') { + return $this->typeResolver->resolve('Schema\\ApiInsightsSummaryStats'); + } + + if ($call === 'GET /orgs/{org}/insights/api/time-stats') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'GET /orgs/{org}/insights/api/time-stats/users/{user_id}') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'GET /orgs/{org}/insights/api/time-stats/{actor_type}/{actor_id}') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'GET /orgs/{org}/insights/api/user-stats/{user_id}') { + return $this->typeResolver->resolve('iterable'); + } + + if ($call === 'LIST /orgs/{org}/insights/api/user-stats/{user_id}') { + return $this->typeResolver->resolve('iterable'); + } + if ($call === 'GET /orgs/{org}/installation') { return $this->typeResolver->resolve(''); } @@ -2336,7 +2384,7 @@ public function getTypeFromMethodCall(MethodReflection $methodReflection, Method } if ($call === 'DELETE /repos/{owner}/{repo}/code-scanning/codeql/databases/{language}') { - return $this->typeResolver->resolve('\\ApiClients\\Tools\\OpenApiClient\\Utils\\Response\\WithoutBody'); + return $this->typeResolver->resolve(''); } if ($call === 'POST /repos/{owner}/{repo}/code-scanning/codeql/variant-analyses') { @@ -2852,7 +2900,7 @@ public function getTypeFromMethodCall(MethodReflection $methodReflection, Method } if ($call === 'GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries') { - return $this->typeResolver->resolve('Observable'); + return $this->typeResolver->resolve('iterable'); } if ($call === 'GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}') { diff --git a/clients/GitHub/src/Schema/ApiInsightsRouteStats.php b/clients/GitHub/src/Schema/ApiInsightsRouteStats.php new file mode 100644 index 00000000000..63e8d3c97dc --- /dev/null +++ b/clients/GitHub/src/Schema/ApiInsightsRouteStats.php @@ -0,0 +1,69 @@ + 'application/json'], json_encode(json_decode(Schema\ApiInsightsSummaryStats::SCHEMA_EXAMPLE_DATA, true))); + $auth = $this->prophesize(AuthenticationInterface::class); + $auth->authHeader(Argument::any())->willReturn('Bearer beer')->shouldBeCalled(); + $browser = $this->prophesize(Browser::class); + $browser->withBase(Argument::any())->willReturn($browser->reveal()); + $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); + $browser->request('GET', '/orgs/generated/insights/api/summary-stats/generated/8?min_timestamp=generated&max_timestamp=generated', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $client = new Client($auth->reveal(), $browser->reveal()); + $result = $client->call(Internal\Operation\ApiInsights\GetSummaryStatsByActor::OPERATION_MATCH, (static function (array $data): array { + $data['org'] = 'generated'; + $data['min_timestamp'] = 'generated'; + $data['max_timestamp'] = 'generated'; + $data['actor_type'] = 'generated'; + $data['actor_id'] = 8; + + return $data; + })([])); + } + + /** @test */ + public function operations_httpCode_200_responseContentType_application_json_zero(): void + { + $response = new Response(200, ['Content-Type' => 'application/json'], json_encode(json_decode(Schema\ApiInsightsSummaryStats::SCHEMA_EXAMPLE_DATA, true))); + $auth = $this->prophesize(AuthenticationInterface::class); + $auth->authHeader(Argument::any())->willReturn('Bearer beer')->shouldBeCalled(); + $browser = $this->prophesize(Browser::class); + $browser->withBase(Argument::any())->willReturn($browser->reveal()); + $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); + $browser->request('GET', '/orgs/generated/insights/api/summary-stats/generated/8?min_timestamp=generated&max_timestamp=generated', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $client = new Client($auth->reveal(), $browser->reveal()); + $result = $client->operations()->apiInsights()->getSummaryStatsByActor('generated', 'generated', 'generated', 'generated', 8); + } +} diff --git a/clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsByUserTest.php b/clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsByUserTest.php new file mode 100644 index 00000000000..166d9888aa4 --- /dev/null +++ b/clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsByUserTest.php @@ -0,0 +1,57 @@ + 'application/json'], json_encode(json_decode(Schema\ApiInsightsSummaryStats::SCHEMA_EXAMPLE_DATA, true))); + $auth = $this->prophesize(AuthenticationInterface::class); + $auth->authHeader(Argument::any())->willReturn('Bearer beer')->shouldBeCalled(); + $browser = $this->prophesize(Browser::class); + $browser->withBase(Argument::any())->willReturn($browser->reveal()); + $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); + $browser->request('GET', '/orgs/generated/insights/api/summary-stats/users/generated?min_timestamp=generated&max_timestamp=generated', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $client = new Client($auth->reveal(), $browser->reveal()); + $result = $client->call(Internal\Operation\ApiInsights\GetSummaryStatsByUser::OPERATION_MATCH, (static function (array $data): array { + $data['org'] = 'generated'; + $data['user_id'] = 'generated'; + $data['min_timestamp'] = 'generated'; + $data['max_timestamp'] = 'generated'; + + return $data; + })([])); + } + + /** @test */ + public function operations_httpCode_200_responseContentType_application_json_zero(): void + { + $response = new Response(200, ['Content-Type' => 'application/json'], json_encode(json_decode(Schema\ApiInsightsSummaryStats::SCHEMA_EXAMPLE_DATA, true))); + $auth = $this->prophesize(AuthenticationInterface::class); + $auth->authHeader(Argument::any())->willReturn('Bearer beer')->shouldBeCalled(); + $browser = $this->prophesize(Browser::class); + $browser->withBase(Argument::any())->willReturn($browser->reveal()); + $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); + $browser->request('GET', '/orgs/generated/insights/api/summary-stats/users/generated?min_timestamp=generated&max_timestamp=generated', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $client = new Client($auth->reveal(), $browser->reveal()); + $result = $client->operations()->apiInsights()->getSummaryStatsByUser('generated', 'generated', 'generated', 'generated'); + } +} diff --git a/clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsTest.php b/clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsTest.php new file mode 100644 index 00000000000..05957ba2606 --- /dev/null +++ b/clients/GitHub/tests/Internal/Operation/ApiInsights/GetSummaryStatsTest.php @@ -0,0 +1,56 @@ + 'application/json'], json_encode(json_decode(Schema\ApiInsightsSummaryStats::SCHEMA_EXAMPLE_DATA, true))); + $auth = $this->prophesize(AuthenticationInterface::class); + $auth->authHeader(Argument::any())->willReturn('Bearer beer')->shouldBeCalled(); + $browser = $this->prophesize(Browser::class); + $browser->withBase(Argument::any())->willReturn($browser->reveal()); + $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); + $browser->request('GET', '/orgs/generated/insights/api/summary-stats?min_timestamp=generated&max_timestamp=generated', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $client = new Client($auth->reveal(), $browser->reveal()); + $result = $client->call(Internal\Operation\ApiInsights\GetSummaryStats::OPERATION_MATCH, (static function (array $data): array { + $data['org'] = 'generated'; + $data['min_timestamp'] = 'generated'; + $data['max_timestamp'] = 'generated'; + + return $data; + })([])); + } + + /** @test */ + public function operations_httpCode_200_responseContentType_application_json_zero(): void + { + $response = new Response(200, ['Content-Type' => 'application/json'], json_encode(json_decode(Schema\ApiInsightsSummaryStats::SCHEMA_EXAMPLE_DATA, true))); + $auth = $this->prophesize(AuthenticationInterface::class); + $auth->authHeader(Argument::any())->willReturn('Bearer beer')->shouldBeCalled(); + $browser = $this->prophesize(Browser::class); + $browser->withBase(Argument::any())->willReturn($browser->reveal()); + $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); + $browser->request('GET', '/orgs/generated/insights/api/summary-stats?min_timestamp=generated&max_timestamp=generated', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $client = new Client($auth->reveal(), $browser->reveal()); + $result = $client->operations()->apiInsights()->getSummaryStats('generated', 'generated', 'generated'); + } +} diff --git a/clients/GitHub/tests/Internal/Operation/ApiInsights/GetTimeStatsByActorTest.php b/clients/GitHub/tests/Internal/Operation/ApiInsights/GetTimeStatsByActorTest.php new file mode 100644 index 00000000000..eee22ce608b --- /dev/null +++ b/clients/GitHub/tests/Internal/Operation/ApiInsights/GetTimeStatsByActorTest.php @@ -0,0 +1,12 @@ +prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/app/hook/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/app/hook/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Apps\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -52,9 +51,9 @@ public function operations_httpCode_400_responseContentType_application_json_zer $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/app/hook/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/app/hook/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->apps()->listWebhookDeliveries('generated', false, 8); + $result = $client->operations()->apps()->listWebhookDeliveries('generated', 8); } /** @test */ @@ -67,12 +66,11 @@ public function call_httpCode_400_responseContentType_application_scim_json_zero $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/app/hook/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/app/hook/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Apps\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -88,9 +86,9 @@ public function operations_httpCode_400_responseContentType_application_scim_jso $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/app/hook/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/app/hook/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->apps()->listWebhookDeliveries('generated', false, 8); + $result = $client->operations()->apps()->listWebhookDeliveries('generated', 8); } /** @test */ @@ -103,12 +101,11 @@ public function call_httpCode_422_responseContentType_application_json_zero(): v $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/app/hook/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/app/hook/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Apps\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -124,8 +121,8 @@ public function operations_httpCode_422_responseContentType_application_json_zer $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/app/hook/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/app/hook/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->apps()->listWebhookDeliveries('generated', false, 8); + $result = $client->operations()->apps()->listWebhookDeliveries('generated', 8); } } diff --git a/clients/GitHub/tests/Internal/Operation/Orgs/ListWebhookDeliveriesTest.php b/clients/GitHub/tests/Internal/Operation/Orgs/ListWebhookDeliveriesTest.php index 89567ca1d5e..fe48f6e17e9 100644 --- a/clients/GitHub/tests/Internal/Operation/Orgs/ListWebhookDeliveriesTest.php +++ b/clients/GitHub/tests/Internal/Operation/Orgs/ListWebhookDeliveriesTest.php @@ -31,14 +31,13 @@ public function call_httpCode_400_responseContentType_application_json_zero(): v $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Orgs\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['org'] = 'generated'; - $data['hook_id'] = 7; - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['org'] = 'generated'; + $data['hook_id'] = 7; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -54,9 +53,9 @@ public function operations_httpCode_400_responseContentType_application_json_zer $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->orgs()->listWebhookDeliveries('generated', 7, 'generated', false, 8); + $result = $client->operations()->orgs()->listWebhookDeliveries('generated', 7, 'generated', 8); } /** @test */ @@ -69,14 +68,13 @@ public function call_httpCode_400_responseContentType_application_scim_json_zero $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Orgs\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['org'] = 'generated'; - $data['hook_id'] = 7; - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['org'] = 'generated'; + $data['hook_id'] = 7; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -92,9 +90,9 @@ public function operations_httpCode_400_responseContentType_application_scim_jso $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->orgs()->listWebhookDeliveries('generated', 7, 'generated', false, 8); + $result = $client->operations()->orgs()->listWebhookDeliveries('generated', 7, 'generated', 8); } /** @test */ @@ -107,14 +105,13 @@ public function call_httpCode_422_responseContentType_application_json_zero(): v $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Orgs\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['org'] = 'generated'; - $data['hook_id'] = 7; - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['org'] = 'generated'; + $data['hook_id'] = 7; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -130,8 +127,8 @@ public function operations_httpCode_422_responseContentType_application_json_zer $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/orgs/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->orgs()->listWebhookDeliveries('generated', 7, 'generated', false, 8); + $result = $client->operations()->orgs()->listWebhookDeliveries('generated', 7, 'generated', 8); } } diff --git a/clients/GitHub/tests/Internal/Operation/Repos/ListWebhookDeliveriesTest.php b/clients/GitHub/tests/Internal/Operation/Repos/ListWebhookDeliveriesTest.php index fb4b01d71e3..0f021f59bac 100644 --- a/clients/GitHub/tests/Internal/Operation/Repos/ListWebhookDeliveriesTest.php +++ b/clients/GitHub/tests/Internal/Operation/Repos/ListWebhookDeliveriesTest.php @@ -31,15 +31,14 @@ public function call_httpCode_400_responseContentType_application_json_zero(): v $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Repos\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['owner'] = 'generated'; - $data['repo'] = 'generated'; - $data['hook_id'] = 7; - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['owner'] = 'generated'; + $data['repo'] = 'generated'; + $data['hook_id'] = 7; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -55,9 +54,9 @@ public function operations_httpCode_400_responseContentType_application_json_zer $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->repos()->listWebhookDeliveries('generated', 'generated', 7, 'generated', false, 8); + $result = $client->operations()->repos()->listWebhookDeliveries('generated', 'generated', 7, 'generated', 8); } /** @test */ @@ -70,15 +69,14 @@ public function call_httpCode_400_responseContentType_application_scim_json_zero $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Repos\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['owner'] = 'generated'; - $data['repo'] = 'generated'; - $data['hook_id'] = 7; - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['owner'] = 'generated'; + $data['repo'] = 'generated'; + $data['hook_id'] = 7; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -94,9 +92,9 @@ public function operations_httpCode_400_responseContentType_application_scim_jso $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->repos()->listWebhookDeliveries('generated', 'generated', 7, 'generated', false, 8); + $result = $client->operations()->repos()->listWebhookDeliveries('generated', 'generated', 7, 'generated', 8); } /** @test */ @@ -109,15 +107,14 @@ public function call_httpCode_422_responseContentType_application_json_zero(): v $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); $result = $client->call(Internal\Operation\Repos\ListWebhookDeliveries::OPERATION_MATCH, (static function (array $data): array { - $data['owner'] = 'generated'; - $data['repo'] = 'generated'; - $data['hook_id'] = 7; - $data['cursor'] = 'generated'; - $data['redelivery'] = false; - $data['per_page'] = 8; + $data['owner'] = 'generated'; + $data['repo'] = 'generated'; + $data['hook_id'] = 7; + $data['cursor'] = 'generated'; + $data['per_page'] = 8; return $data; })([])); @@ -133,8 +130,8 @@ public function operations_httpCode_422_responseContentType_application_json_zer $browser = $this->prophesize(Browser::class); $browser->withBase(Argument::any())->willReturn($browser->reveal()); $browser->withFollowRedirects(Argument::any())->willReturn($browser->reveal()); - $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&redelivery=&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); + $browser->request('GET', '/repos/generated/generated/hooks/7/deliveries?cursor=generated&per_page=8', Argument::type('array'), Argument::any())->willReturn(resolve($response))->shouldBeCalled(); $client = new Client($auth->reveal(), $browser->reveal()); - $result = $client->operations()->repos()->listWebhookDeliveries('generated', 'generated', 7, 'generated', false, 8); + $result = $client->operations()->repos()->listWebhookDeliveries('generated', 'generated', 7, 'generated', 8); } } diff --git a/clients/GitHub/tests/Types/ClientCallReturnTypes.php b/clients/GitHub/tests/Types/ClientCallReturnTypes.php index fe1726270f7..78cf659d72d 100644 --- a/clients/GitHub/tests/Types/ClientCallReturnTypes.php +++ b/clients/GitHub/tests/Types/ClientCallReturnTypes.php @@ -24,7 +24,7 @@ function authHeader(): string assertType('', $client->call('POST /app-manifests/{code}/conversions')); assertType('', $client->call('GET /app/hook/config')); assertType('', $client->call('PATCH /app/hook/config')); -assertType('Observable', $client->call('GET /app/hook/deliveries')); +assertType('iterable', $client->call('GET /app/hook/deliveries')); assertType('', $client->call('GET /app/hook/deliveries/{delivery_id}')); assertType('', $client->call('POST /app/hook/deliveries/{delivery_id}/attempts')); assertType('Observable|WithoutBody', $client->call('GET /app/installation-requests')); @@ -252,10 +252,22 @@ function authHeader(): string assertType('', $client->call('PATCH /orgs/{org}/hooks/{hook_id}')); assertType('', $client->call('GET /orgs/{org}/hooks/{hook_id}/config')); assertType('', $client->call('PATCH /orgs/{org}/hooks/{hook_id}/config')); -assertType('Observable', $client->call('GET /orgs/{org}/hooks/{hook_id}/deliveries')); +assertType('iterable', $client->call('GET /orgs/{org}/hooks/{hook_id}/deliveries')); assertType('', $client->call('GET /orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}')); assertType('', $client->call('POST /orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}/attempts')); assertType('', $client->call('POST /orgs/{org}/hooks/{hook_id}/pings')); +assertType('iterable', $client->call('GET /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}')); +assertType('iterable', $client->call('LIST /orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}')); +assertType('iterable', $client->call('GET /orgs/{org}/insights/api/subject-stats')); +assertType('iterable', $client->call('LIST /orgs/{org}/insights/api/subject-stats')); +assertType('Schema\\ApiInsightsSummaryStats', $client->call('GET /orgs/{org}/insights/api/summary-stats')); +assertType('Schema\\ApiInsightsSummaryStats', $client->call('GET /orgs/{org}/insights/api/summary-stats/users/{user_id}')); +assertType('Schema\\ApiInsightsSummaryStats', $client->call('GET /orgs/{org}/insights/api/summary-stats/{actor_type}/{actor_id}')); +assertType('iterable', $client->call('GET /orgs/{org}/insights/api/time-stats')); +assertType('iterable', $client->call('GET /orgs/{org}/insights/api/time-stats/users/{user_id}')); +assertType('iterable', $client->call('GET /orgs/{org}/insights/api/time-stats/{actor_type}/{actor_id}')); +assertType('iterable', $client->call('GET /orgs/{org}/insights/api/user-stats/{user_id}')); +assertType('iterable', $client->call('LIST /orgs/{org}/insights/api/user-stats/{user_id}')); assertType('', $client->call('GET /orgs/{org}/installation')); assertType('', $client->call('GET /orgs/{org}/installations')); assertType('', $client->call('GET /orgs/{org}/interaction-limits')); @@ -590,7 +602,7 @@ function authHeader(): string assertType('', $client->call('DELETE /repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}')); assertType('Observable', $client->call('GET /repos/{owner}/{repo}/code-scanning/codeql/databases')); assertType('', $client->call('GET /repos/{owner}/{repo}/code-scanning/codeql/databases/{language}')); -assertType('\\ApiClients\\Tools\\OpenApiClient\\Utils\\Response\\WithoutBody', $client->call('DELETE /repos/{owner}/{repo}/code-scanning/codeql/databases/{language}')); +assertType('', $client->call('DELETE /repos/{owner}/{repo}/code-scanning/codeql/databases/{language}')); assertType('', $client->call('POST /repos/{owner}/{repo}/code-scanning/codeql/variant-analyses')); assertType('', $client->call('GET /repos/{owner}/{repo}/code-scanning/codeql/variant-analyses/{codeql_variant_analysis_id}')); assertType('', $client->call('GET /repos/{owner}/{repo}/code-scanning/codeql/variant-analyses/{codeql_variant_analysis_id}/repos/{repo_owner}/{repo_name}')); @@ -719,7 +731,7 @@ function authHeader(): string assertType('', $client->call('PATCH /repos/{owner}/{repo}/hooks/{hook_id}')); assertType('', $client->call('GET /repos/{owner}/{repo}/hooks/{hook_id}/config')); assertType('', $client->call('PATCH /repos/{owner}/{repo}/hooks/{hook_id}/config')); -assertType('Observable', $client->call('GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries')); +assertType('iterable', $client->call('GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries')); assertType('', $client->call('GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}')); assertType('', $client->call('POST /repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}/attempts')); assertType('', $client->call('POST /repos/{owner}/{repo}/hooks/{hook_id}/pings')); diff --git a/etc/specs/GitHub/current.spec.yaml b/etc/specs/GitHub/current.spec.yaml index 749fd4fd1f5..cd3043cc833 100644 --- a/etc/specs/GitHub/current.spec.yaml +++ b/etc/specs/GitHub/current.spec.yaml @@ -505,11 +505,6 @@ paths: parameters: - "$ref": "#/components/parameters/per-page" - "$ref": "#/components/parameters/cursor" - - name: redelivery - in: query - required: false - schema: - type: boolean responses: '200': description: Response @@ -9865,11 +9860,6 @@ paths: - "$ref": "#/components/parameters/hook-id" - "$ref": "#/components/parameters/per-page" - "$ref": "#/components/parameters/cursor" - - name: redelivery - in: query - required: false - schema: - type: boolean responses: '200': description: Response @@ -9992,6 +9982,292 @@ paths: enabledForGitHubApps: true category: orgs subcategory: webhooks + "/orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id}": + get: + summary: Get route stats by actor + description: Get API request count statistics for an actor broken down by route + within a specified time frame. + tags: + - orgs + operationId: api-insights/get-route-stats-by-actor + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-route-stats-by-actor + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-actor-type" + - "$ref": "#/components/parameters/api-insights-actor-id" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + - "$ref": "#/components/parameters/page" + - "$ref": "#/components/parameters/per-page" + - "$ref": "#/components/parameters/direction" + - "$ref": "#/components/parameters/api-insights-route-stats-sort" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-route-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-route-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/subject-stats": + get: + summary: Get subject stats + description: Get API request statistics for all subjects within an organization + within a specified time frame. Subjects can be users or GitHub Apps. + tags: + - orgs + operationId: api-insights/get-subject-stats + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-subject-stats + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + - "$ref": "#/components/parameters/page" + - "$ref": "#/components/parameters/per-page" + - "$ref": "#/components/parameters/direction" + - "$ref": "#/components/parameters/api-insights-sort" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-subject-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-subject-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/summary-stats": + get: + summary: Get summary stats + description: Get overall statistics of API requests made within an organization + by all users and apps within a specified time frame. + tags: + - orgs + operationId: api-insights/get-summary-stats + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-summary-stats + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-summary-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-summary-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/summary-stats/users/{user_id}": + get: + summary: Get summary stats by user + description: Get overall statistics of API requests within the organization + for a user. + tags: + - orgs + operationId: api-insights/get-summary-stats-by-user + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-summary-stats-by-user + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-user-id" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-summary-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-summary-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/summary-stats/{actor_type}/{actor_id}": + get: + summary: Get summary stats by actor + description: Get overall statistics of API requests within the organization + made by a specific actor. Actors can be GitHub App installations, OAuth apps + or other tokens on behalf of a user. + tags: + - orgs + operationId: api-insights/get-summary-stats-by-actor + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-summary-stats-by-actor + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + - "$ref": "#/components/parameters/api-insights-actor-type" + - "$ref": "#/components/parameters/api-insights-actor-id" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-summary-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-summary-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/time-stats": + get: + summary: Get time stats + description: Get the number of API requests and rate-limited requests made within + an organization over a specified time period. + tags: + - orgs + operationId: api-insights/get-time-stats + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-time-stats + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + - "$ref": "#/components/parameters/api-insights-timestamp-increment" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-time-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-time-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/time-stats/users/{user_id}": + get: + summary: Get time stats by user + description: Get the number of API requests and rate-limited requests made within + an organization by a specific user over a specified time period. + tags: + - orgs + operationId: api-insights/get-time-stats-by-user + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-time-stats-by-user + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-user-id" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + - "$ref": "#/components/parameters/api-insights-timestamp-increment" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-time-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-time-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/time-stats/{actor_type}/{actor_id}": + get: + summary: Get time stats by actor + description: Get the number of API requests and rate-limited requests made within + an organization by a specific actor within a specified time period. + tags: + - orgs + operationId: api-insights/get-time-stats-by-actor + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-time-stats-by-actor + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-actor-type" + - "$ref": "#/components/parameters/api-insights-actor-id" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + - "$ref": "#/components/parameters/api-insights-timestamp-increment" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-time-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-time-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights + "/orgs/{org}/insights/api/user-stats/{user_id}": + get: + summary: Get user stats + description: Get API usage statistics within an organization for a user broken + down by the type of access. + tags: + - orgs + operationId: api-insights/get-user-stats + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/orgs/api-insights#get-user-stats + parameters: + - "$ref": "#/components/parameters/org" + - "$ref": "#/components/parameters/api-insights-user-id" + - "$ref": "#/components/parameters/api-insights-min-timestamp" + - "$ref": "#/components/parameters/api-insights-max-timestamp" + - "$ref": "#/components/parameters/page" + - "$ref": "#/components/parameters/per-page" + - "$ref": "#/components/parameters/direction" + - "$ref": "#/components/parameters/api-insights-sort" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/api-insights-user-stats" + examples: + default: + "$ref": "#/components/examples/api-insights-user-stats" + x-github: + enabledForGitHubApps: true + category: orgs + subcategory: api-insights "/orgs/{org}/installation": get: summary: Get an organization installation for the authenticated app @@ -11712,7 +11988,7 @@ paths: description: |- Lists packages in an organization readable by the user. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/list-packages-for-organization @@ -11782,7 +12058,7 @@ paths: description: |- Gets a specific package in an organization. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-package-for-organization @@ -11815,7 +12091,7 @@ paths: The authenticated user must have admin permissions in the organization to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must also have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/delete-package-for-org @@ -11852,7 +12128,7 @@ paths: The authenticated user must have admin permissions in the organization to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must also have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/restore-package-for-org @@ -11889,7 +12165,7 @@ paths: description: |- Lists package versions for a package owned by an organization. - OAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint if the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-all-package-versions-for-package-owned-by-org @@ -11941,7 +12217,7 @@ paths: description: |- Gets a specific package version in an organization. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-package-version-for-organization @@ -11975,7 +12251,7 @@ paths: The authenticated user must have admin permissions in the organization to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must also have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/delete-package-version-for-org @@ -12013,7 +12289,7 @@ paths: The authenticated user must have admin permissions in the organization to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must also have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/restore-package-version-for-org @@ -30827,11 +31103,6 @@ paths: - "$ref": "#/components/parameters/hook-id" - "$ref": "#/components/parameters/per-page" - "$ref": "#/components/parameters/cursor" - - name: redelivery - in: query - required: false - schema: - type: boolean responses: '200': description: Response @@ -45747,7 +46018,7 @@ paths: description: |- Lists packages owned by the authenticated user within the user's namespace. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/list-packages-for-authenticated-user @@ -45800,7 +46071,7 @@ paths: description: |- Gets a specific package for a package owned by the authenticated user. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-package-for-authenticated-user @@ -45830,7 +46101,7 @@ paths: description: |- Deletes a package owned by the authenticated user. You cannot delete a public package if any version of the package has more than 5,000 downloads. In this scenario, contact GitHub support for further assistance. - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, `repo` scope is also required. For the list these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/delete-package-for-authenticated-user @@ -45864,7 +46135,7 @@ paths: - The package was deleted within the last 30 days. - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first. - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/restore-package-for-authenticated-user @@ -45900,7 +46171,7 @@ paths: description: |- Lists package versions for a package owned by the authenticated user. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-all-package-versions-for-package-owned-by-authenticated-user @@ -45951,7 +46222,7 @@ paths: description: |- Gets a specific package version for a package owned by the authenticated user. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-package-version-for-authenticated-user @@ -45984,7 +46255,7 @@ paths: The authenticated user must have admin permissions in the organization to use this endpoint. - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/delete-package-version-for-authenticated-user @@ -46019,7 +46290,7 @@ paths: - The package was deleted within the last 30 days. - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first. - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/restore-package-version-for-authenticated-user @@ -47801,7 +48072,7 @@ paths: description: |- Lists all packages in a user's namespace for which the requesting user has access. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/list-packages-for-user @@ -47859,7 +48130,7 @@ paths: description: |- Gets a specific package metadata for a public package owned by a user. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-package-for-user @@ -47892,7 +48163,7 @@ paths: If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/delete-package-for-user @@ -47929,7 +48200,7 @@ paths: If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/restore-package-for-user @@ -47966,7 +48237,7 @@ paths: description: |- Lists package versions for a public package owned by a specified user. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-all-package-versions-for-package-owned-by-user @@ -48006,7 +48277,7 @@ paths: description: |- Gets a specific package version for a public package owned by a specified user. - OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` scope to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/get-package-version-for-user @@ -48040,7 +48311,7 @@ paths: If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `delete:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/delete-package-version-for-user @@ -48078,7 +48349,7 @@ paths: If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, the authenticated user must have admin permissions to the package. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages)." - OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, the `repo` scope is also required. For the list of these registries, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." + OAuth app tokens and personal access tokens (classic) need the `read:packages` and `write:packages` scopes to use this endpoint. For more information, see "[About permissions for GitHub Packages](https://docs.github.com/packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages)." tags: - packages operationId: packages/restore-package-version-for-user @@ -73935,6 +74206,121 @@ components: - ping_url - created_at - updated_at + api-insights-route-stats: + title: Route Stats + description: API Insights usage route stats for an actor + type: array + items: + type: object + properties: + http_method: + description: The HTTP method + type: string + api_route: + description: The API path's route template + type: string + total_request_count: + description: The total number of requests within the queried time period + type: integer + format: int64 + rate_limited_request_count: + description: The total number of requests that were rate limited within + the queried time period + type: integer + format: int64 + last_rate_limited_timestamp: + type: + - string + - 'null' + last_request_timestamp: + type: string + api-insights-subject-stats: + title: Subject Stats + description: API Insights usage subject stats for an organization + type: array + items: + type: object + properties: + subject_type: + type: string + subject_name: + type: string + subject_id: + type: integer + format: int64 + total_request_count: + type: integer + rate_limited_request_count: + type: integer + last_rate_limited_timestamp: + type: + - string + - 'null' + last_request_timestamp: + type: string + api-insights-summary-stats: + title: Summary Stats + description: API Insights usage summary stats for an organization + type: object + properties: + total_request_count: + description: The total number of requests within the queried time period + type: integer + format: int64 + rate_limited_request_count: + description: The total number of requests that were rate limited within + the queried time period + type: integer + format: int64 + api-insights-time-stats: + title: Time Stats + description: API Insights usage time stats for an organization + type: array + items: + type: object + properties: + timestamp: + type: string + total_request_count: + type: integer + format: int64 + rate_limited_request_count: + type: integer + format: int64 + api-insights-user-stats: + title: User Stats + description: API Insights usage stats for a user + type: array + items: + type: object + properties: + actor_type: + type: string + actor_name: + type: string + actor_id: + type: integer + format: int64 + integration_id: + type: + - integer + - 'null' + format: int64 + oauth_application_id: + type: + - integer + - 'null' + format: int64 + total_request_count: + type: integer + rate_limited_request_count: + type: integer + last_rate_limited_timestamp: + type: + - string + - 'null' + last_request_timestamp: + type: string interaction-group: type: string description: The type of GitHub user that can comment, open issues, or create @@ -74503,6 +74889,11 @@ components: created_at: type: string description: Date and time when the request for access was created. + token_id: + type: integer + description: Unique identifier of the user's token. This field can also + be found in audit log events and the organization's settings for their + PAT grants. token_expired: type: boolean description: Whether the associated fine-grained personal access token has @@ -74527,6 +74918,7 @@ components: - repositories_url - permissions - created_at + - token_id - token_expired - token_expires_at - token_last_used_at @@ -74538,9 +74930,9 @@ components: properties: id: type: integer - description: Unique identifier of the fine-grained personal access token. - The `pat_id` used to get details about an approved fine-grained personal - access token. + description: Unique identifier of the fine-grained personal access token + grant. The `pat_id` used to get details about an approved fine-grained + personal access token. owner: "$ref": "#/components/schemas/simple-user" repository_selection: @@ -74574,6 +74966,11 @@ components: type: string description: Date and time when the fine-grained personal access token was approved to access the organization. + token_id: + type: integer + description: Unique identifier of the user's token. This field can also + be found in audit log events and the organization's settings for their + PAT grants. token_expired: type: boolean description: Whether the associated fine-grained personal access token has @@ -74597,6 +74994,7 @@ components: - repositories_url - permissions - access_granted_at + - token_id - token_expired - token_expires_at - token_last_used_at @@ -80950,6 +81348,7 @@ components: properties: id: type: integer + format: int64 examples: - 5 node_id: @@ -96531,6 +96930,11 @@ components: created_at: type: string description: Date and time when the request for access was created. + token_id: + type: integer + description: Unique identifier of the user's token. This field can also + be found in audit log events and the organization's settings for their + PAT grants. token_expired: type: boolean description: Whether the associated fine-grained personal access token has @@ -96557,6 +96961,7 @@ components: - repository_count - repositories - created_at + - token_id - token_expired - token_expires_at - token_last_used_at @@ -205040,6 +205445,58 @@ components: updated_at: '2011-09-06T20:39:23Z' created_at: '2011-09-06T17:26:27Z' type: Organization + api-insights-route-stats: + value: + - http_method: GET + api_route: "/repositories/:repository_id" + total_request_count: 544665 + rate_limited_request_count: 13 + last_request_timestamp: '2024-09-18T15:43:03Z' + last_rate_limited_timestamp: '2024-09-18T06:30:09Z' + api-insights-subject-stats: + value: + - subject_type: installation + subject_id: 954453 + subject_name: GitHub Actions + integration_id: 124345 + total_request_count: 544665 + rate_limited_request_count: 13 + last_request_timestamp: '2024-09-18T15:43:03Z' + last_rate_limited_timestamp: '2024-09-18T06:30:09Z' + api-insights-summary-stats: + value: + total_request_count: 34225 + rate_limited_request_count: 23 + api-insights-time-stats: + value: + - timestamp: '2024-09-11T15:00:00Z' + total_request_count: 34225 + rate_limited_request_count: 0 + - timestamp: '2024-09-11T15:05:00Z' + total_request_count: 10587 + rate_limited_request_count: 18 + - timestamp: '2024-09-11T15:10:00Z' + total_request_count: 43587 + rate_limited_request_count: 14 + - timestamp: '2024-09-11T15:15:00Z' + total_request_count: 19463 + rate_limited_request_count: 4 + - timestamp: '2024-09-11T15:20:00Z' + total_request_count: 60542 + rate_limited_request_count: 3 + - timestamp: '2024-09-11T15:25:00Z' + total_request_count: 55872 + rate_limited_request_count: 23 + api-insights-user-stats: + value: + - actor_type: oauth_app + actor_id: 954453 + actor_name: GitHub Actions + oauth_application_id: 1245 + total_request_count: 544665 + rate_limited_request_count: 13 + last_request_timestamp: '2024-09-18T15:43:03Z' + last_rate_limited_timestamp: '2024-09-18T06:30:09Z' installation: value: id: 1 @@ -206146,6 +206603,7 @@ components: repository: metadata: read created_at: '2023-05-16T08:47:09.000-07:00' + token_id: 98716 token_expired: false token_expires_at: '2023-11-16T08:47:09.000-07:00' token_last_used_at: @@ -206179,6 +206637,7 @@ components: repository: metadata: read access_granted_at: '2023-05-16T08:47:09.000-07:00' + token_id: 98716 token_expired: false token_expires_at: '2023-11-16T08:47:09.000-07:00' token_last_used_at: @@ -225319,6 +225778,88 @@ components: required: true schema: type: integer + api-insights-actor-type: + name: actor_type + in: path + description: The type of the actor + required: true + schema: + type: string + enum: + - installations + - classic_pats + - fine_grained_pats + - oauth_apps + - github_apps_user_to_server + api-insights-actor-id: + name: actor_id + in: path + description: The ID of the actor + required: true + schema: + type: integer + api-insights-min-timestamp: + name: min_timestamp + description: The minimum timestamp to query for stats + in: query + required: true + schema: + type: string + api-insights-max-timestamp: + name: max_timestamp + description: The maximum timestamp to query for stats + in: query + required: true + schema: + type: string + api-insights-route-stats-sort: + name: sort + description: The property to sort the results by. + in: query + required: false + schema: + type: array + items: + type: string + enum: + - last_rate_limited_timestamp + - last_request_timestamp + - rate_limited_request_count + - http_method + - api_route + - total_request_count + default: total_request_count + api-insights-sort: + name: sort + description: The property to sort the results by. + in: query + required: false + schema: + type: array + items: + type: string + enum: + - last_rate_limited_timestamp + - last_request_timestamp + - rate_limited_request_count + - subject_name + - total_request_count + default: total_request_count + api-insights-user-id: + name: user_id + in: path + description: The ID of the user to query for stats + required: true + schema: + type: string + api-insights-timestamp-increment: + name: timestamp_increment + description: The increment of time used to breakdown the query results (5m, + 10m, 1h, etc.) + in: query + required: true + schema: + type: string invitation-id: name: invitation_id description: The unique identifier of the invitation.