{"id":22089859,"url":"https://github.com/speakeasy-api/speakeasy-client-sdk-php","last_synced_at":"2025-07-24T19:31:35.608Z","repository":{"id":65794077,"uuid":"599977157","full_name":"speakeasy-api/speakeasy-client-sdk-php","owner":"speakeasy-api","description":null,"archived":false,"fork":false,"pushed_at":"2024-11-28T00:17:50.000Z","size":1942,"stargazers_count":0,"open_issues_count":0,"forks_count":2,"subscribers_count":6,"default_branch":"main","last_synced_at":"2024-11-30T19:44:54.720Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/speakeasy-api.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-02-10T09:56:17.000Z","updated_at":"2024-11-28T00:17:54.000Z","dependencies_parsed_at":null,"dependency_job_id":"69777ded-07f9-4797-bd96-131cba21cf46","html_url":"https://github.com/speakeasy-api/speakeasy-client-sdk-php","commit_stats":{"total_commits":41,"total_committers":3,"mean_commits":"13.666666666666666","dds":"0.31707317073170727","last_synced_commit":"cdf10b86a2c6b239637f47e9dcaf58cf75f451cd"},"previous_names":[],"tags_count":153,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/speakeasy-api%2Fspeakeasy-client-sdk-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/speakeasy-api%2Fspeakeasy-client-sdk-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/speakeasy-api%2Fspeakeasy-client-sdk-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/speakeasy-api%2Fspeakeasy-client-sdk-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/speakeasy-api","download_url":"https://codeload.github.com/speakeasy-api/speakeasy-client-sdk-php/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227470069,"owners_count":17778930,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-01T02:14:29.699Z","updated_at":"2025-07-24T19:31:35.580Z","avatar_url":"https://github.com/speakeasy-api.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# speakeasy-api/speakeasy-client-sdk-php\n\n\u003c!-- Start SDK Installation [installation] --\u003e\n## SDK Installation\n\nThe SDK relies on [Composer](https://getcomposer.org/) to manage its dependencies.\n\nTo install the SDK and add it as a dependency to an existing `composer.json` file:\n```bash\ncomposer require \"ian-speakeasy/speakeasy-client-sdk-php\"\n```\n\u003c!-- End SDK Installation [installation] --\u003e\n\n\u003c!-- Start SDK Example Usage [usage] --\u003e\n## SDK Example Usage\n\n### Example\n\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Shared;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()\n    -\u003esetSecurity(\n        new Shared\\Security(\n            apiKey: '\u003cYOUR_API_KEY_HERE\u003e',\n        )\n    )\n    -\u003ebuild();\n\n$request = new Shared\\RemoteSource(\n    inputs: [\n        new Shared\\RemoteDocument(\n            registryUrl: 'https://productive-swine.net',\n        ),\n    ],\n    output: new Shared\\RemoteDocument(\n        registryUrl: 'https://spiteful-apricot.info',\n    ),\n);\n\n$response = $sdk-\u003eartifacts-\u003ecreateRemoteSource(\n    request: $request\n);\n\nif ($response-\u003estatusCode === 200) {\n    // handle response\n}\n```\n\u003c!-- End SDK Example Usage [usage] --\u003e\n\n\u003c!-- Start Authentication [security] --\u003e\n## Authentication\n\n### Per-Client Security Schemes\n\nThis SDK supports the following security schemes globally:\n\n| Name                  | Type   | Scheme      |\n| --------------------- | ------ | ----------- |\n| `apiKey`              | apiKey | API key     |\n| `bearer`              | http   | HTTP Bearer |\n| `workspaceIdentifier` | apiKey | API key     |\n\nYou can set the security parameters through the `setSecurity` function on the `SDKBuilder` when initializing the SDK. The selected scheme will be used by default to authenticate with the API for all operations that support it. For example:\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Shared;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()\n    -\u003esetSecurity(\n        new Shared\\Security(\n            apiKey: '\u003cYOUR_API_KEY_HERE\u003e',\n        )\n    )\n    -\u003ebuild();\n\n$request = new Shared\\RemoteSource(\n    inputs: [\n        new Shared\\RemoteDocument(\n            registryUrl: 'https://productive-swine.net',\n        ),\n    ],\n    output: new Shared\\RemoteDocument(\n        registryUrl: 'https://spiteful-apricot.info',\n    ),\n);\n\n$response = $sdk-\u003eartifacts-\u003ecreateRemoteSource(\n    request: $request\n);\n\nif ($response-\u003estatusCode === 200) {\n    // handle response\n}\n```\n\u003c!-- End Authentication [security] --\u003e\n\n\u003c!-- Start Available Resources and Operations [operations] --\u003e\n## Available Resources and Operations\n\n\u003cdetails open\u003e\n\u003csummary\u003eAvailable methods\u003c/summary\u003e\n\n### [artifacts](docs/sdks/artifacts/README.md)\n\n* [createRemoteSource](docs/sdks/artifacts/README.md#createremotesource) - Configure a new remote source\n* [getBlob](docs/sdks/artifacts/README.md#getblob) - Get blob for a particular digest\n* [getManifest](docs/sdks/artifacts/README.md#getmanifest) - Get manifest for a particular reference\n* [getNamespaces](docs/sdks/artifacts/README.md#getnamespaces) - Each namespace contains many revisions.\n* [getRevisions](docs/sdks/artifacts/README.md#getrevisions)\n* [getTags](docs/sdks/artifacts/README.md#gettags)\n* [listRemoteSources](docs/sdks/artifacts/README.md#listremotesources) - Get remote sources attached to a particular namespace\n* [postTags](docs/sdks/artifacts/README.md#posttags) - Add tags to an existing revision\n* [preflight](docs/sdks/artifacts/README.md#preflight) - Get access token for communicating with OCI distribution endpoints\n* [setArchived](docs/sdks/artifacts/README.md#setarchived) - Set whether a namespace is archived\n* [setVisibility](docs/sdks/artifacts/README.md#setvisibility) - Set visibility of a namespace with an existing metadata entry\n\n### [auth](docs/sdks/auth/README.md)\n\n* [getAccess](docs/sdks/auth/README.md#getaccess) - Get access allowances for a particular workspace\n* [getAccessToken](docs/sdks/auth/README.md#getaccesstoken) - Get or refresh an access token for the current workspace.\n* [getUser](docs/sdks/auth/README.md#getuser) - Get information about the current user.\n* [validateApiKey](docs/sdks/auth/README.md#validateapikey) - Validate the current api key.\n\n### [codeSamples](docs/sdks/codesamples/README.md)\n\n* [generateCodeSamplePreview](docs/sdks/codesamples/README.md#generatecodesamplepreview) - Generate Code Sample previews from a file and configuration parameters.\n* [generateCodeSamplePreviewAsync](docs/sdks/codesamples/README.md#generatecodesamplepreviewasync) - Initiate asynchronous Code Sample preview generation from a file and configuration parameters, receiving an async JobID response for polling.\n* [get](docs/sdks/codesamples/README.md#get) - Retrieve usage snippets\n* [getCodeSamplePreviewAsync](docs/sdks/codesamples/README.md#getcodesamplepreviewasync) - Poll for the result of an asynchronous Code Sample preview generation.\n\n### [events](docs/sdks/events/README.md)\n\n* [getEventsByTarget](docs/sdks/events/README.md#geteventsbytarget) - Load recent events for a particular workspace\n* [getTargets](docs/sdks/events/README.md#gettargets) - Load targets for a particular workspace\n* [getTargetsDeprecated](docs/sdks/events/README.md#gettargetsdeprecated) - Load targets for a particular workspace\n* [post](docs/sdks/events/README.md#post) - Post events for a specific workspace\n* [search](docs/sdks/events/README.md#search) - Search events for a particular workspace by any field\n\n### [github](docs/sdks/github/README.md)\n\n* [checkAccess](docs/sdks/github/README.md#checkaccess)\n* [checkPublishingPRs](docs/sdks/github/README.md#checkpublishingprs)\n* [checkPublishingSecrets](docs/sdks/github/README.md#checkpublishingsecrets)\n* [configureCodeSamples](docs/sdks/github/README.md#configurecodesamples)\n* [configureMintlifyRepo](docs/sdks/github/README.md#configuremintlifyrepo)\n* [configureTarget](docs/sdks/github/README.md#configuretarget)\n* [getAction](docs/sdks/github/README.md#getaction)\n* [getSetup](docs/sdks/github/README.md#getsetup)\n* [linkGithub](docs/sdks/github/README.md#linkgithub)\n* [storePublishingSecrets](docs/sdks/github/README.md#storepublishingsecrets)\n* [triggerAction](docs/sdks/github/README.md#triggeraction)\n\n### [organizations](docs/sdks/organizations/README.md)\n\n* [create](docs/sdks/organizations/README.md#create) - Create an organization\n* [createBillingAddOns](docs/sdks/organizations/README.md#createbillingaddons) - Create billing add ons\n* [createFreeTrial](docs/sdks/organizations/README.md#createfreetrial) - Create a free trial for an organization\n* [deleteBillingAddOn](docs/sdks/organizations/README.md#deletebillingaddon) - Delete billing add ons\n* [get](docs/sdks/organizations/README.md#get) - Get organization\n* [getAll](docs/sdks/organizations/README.md#getall) - Get organizations for a user\n* [getBillingAddOns](docs/sdks/organizations/README.md#getbillingaddons) - Get billing add ons\n* [getUsage](docs/sdks/organizations/README.md#getusage) - Get billing usage summary for a particular organization\n\n### [publishingTokens](docs/sdks/publishingtokens/README.md)\n\n* [create](docs/sdks/publishingtokens/README.md#create) - Create a publishing token for a workspace\n* [delete](docs/sdks/publishingtokens/README.md#delete) - Delete a specific publishing token\n* [get](docs/sdks/publishingtokens/README.md#get) - Get a specific publishing token\n* [list](docs/sdks/publishingtokens/README.md#list) - Get publishing tokens for a workspace\n* [resolveMetadata](docs/sdks/publishingtokens/README.md#resolvemetadata) - Get metadata about the token\n* [resolveTarget](docs/sdks/publishingtokens/README.md#resolvetarget) - Get a specific publishing token target\n* [update](docs/sdks/publishingtokens/README.md#update) - Updates the validitity period of a publishing token\n\n### [reports](docs/sdks/reports/README.md)\n\n* [getChangesReportSignedUrl](docs/sdks/reports/README.md#getchangesreportsignedurl) - Get the signed access url for the change reports for a particular document.\n* [getLintingReportSignedUrl](docs/sdks/reports/README.md#getlintingreportsignedurl) - Get the signed access url for the linting reports for a particular document.\n* [uploadReport](docs/sdks/reports/README.md#uploadreport) - Upload a report.\n\n### [schemaStore](docs/sdks/schemastore/README.md)\n\n* [createSchemaStoreItem](docs/sdks/schemastore/README.md#createschemastoreitem) - Create a schema in the schema store\n* [getSchemaStoreItem](docs/sdks/schemastore/README.md#getschemastoreitem) - Get a OAS schema from the schema store\n\n\n### [shortURLs](docs/sdks/shorturls/README.md)\n\n* [create](docs/sdks/shorturls/README.md#create) - Shorten a URL.\n\n### [subscriptions](docs/sdks/subscriptions/README.md)\n\n* [activateSubscriptionNamespace](docs/sdks/subscriptions/README.md#activatesubscriptionnamespace) - Activate an ignored namespace for a subscription\n* [ignoreSubscriptionNamespace](docs/sdks/subscriptions/README.md#ignoresubscriptionnamespace) - Ignored a namespace for a subscription\n\n### [suggest](docs/sdks/suggest/README.md)\n\n* [suggest](docs/sdks/suggest/README.md#suggest) - Generate suggestions for improving an OpenAPI document.\n* [suggestItems](docs/sdks/suggest/README.md#suggestitems) - Generate generic suggestions for a list of items.\n* [suggestOpenAPI](docs/sdks/suggest/README.md#suggestopenapi) - (DEPRECATED) Generate suggestions for improving an OpenAPI document.\n* [suggestOpenAPIRegistry](docs/sdks/suggest/README.md#suggestopenapiregistry) - Generate suggestions for improving an OpenAPI document stored in the registry.\n\n### [workspaces](docs/sdks/workspaces/README.md)\n\n* [create](docs/sdks/workspaces/README.md#create) - Create a workspace\n* [createToken](docs/sdks/workspaces/README.md#createtoken) - Create a token for a particular workspace\n* [deleteToken](docs/sdks/workspaces/README.md#deletetoken) - Delete a token for a particular workspace\n* [get](docs/sdks/workspaces/README.md#get) - Get workspace by context\n* [getAll](docs/sdks/workspaces/README.md#getall) - Get workspaces for a user\n* [getByID](docs/sdks/workspaces/README.md#getbyid) - Get workspace\n* [getFeatureFlags](docs/sdks/workspaces/README.md#getfeatureflags) - Get workspace feature flags\n* [getSettings](docs/sdks/workspaces/README.md#getsettings) - Get workspace settings\n* [getTeam](docs/sdks/workspaces/README.md#getteam) - Get team members for a particular workspace\n* [getTokens](docs/sdks/workspaces/README.md#gettokens) - Get tokens for a particular workspace\n* [grantAccess](docs/sdks/workspaces/README.md#grantaccess) - Grant a user access to a particular workspace\n* [revokeAccess](docs/sdks/workspaces/README.md#revokeaccess) - Revoke a user's access to a particular workspace\n* [setFeatureFlags](docs/sdks/workspaces/README.md#setfeatureflags) - Set workspace feature flags\n* [update](docs/sdks/workspaces/README.md#update) - Update workspace details\n* [updateSettings](docs/sdks/workspaces/README.md#updatesettings) - Update workspace settings\n\n\u003c/details\u003e\n\u003c!-- End Available Resources and Operations [operations] --\u003e\n\n\n\n\u003c!-- Start Global Parameters [global-parameters] --\u003e\n## Global Parameters\n\nA parameter is configured globally. This parameter may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, This global value will be used as the default on the operations that use it. When such operations are called, there is a place in each to override the global value, if needed.\n\nFor example, you can set `workspace_id` to `'\u003cid\u003e'` at SDK initialization and then you do not have to pass the same value on calls to operations like `getAccessToken`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.\n\n\n### Available Globals\n\nThe following global parameter is available.\n\n| Name        | Type   | Description                |\n| ----------- | ------ | -------------------------- |\n| workspaceId | string | The workspaceId parameter. |\n\n### Example\n\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Operations;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()-\u003ebuild();\n\n$request = new Operations\\GetAccessTokenRequest(\n    workspaceId: '\u003cid\u003e',\n);\n\n$response = $sdk-\u003eauth-\u003egetAccessToken(\n    request: $request\n);\n\nif ($response-\u003eaccessToken !== null) {\n    // handle response\n}\n```\n\u003c!-- End Global Parameters [global-parameters] --\u003e\n\n\u003c!-- Start Retries [retries] --\u003e\n## Retries\n\nSome of the endpoints in this SDK support retries. If you use the SDK without any configuration, it will fall back to the default retry strategy provided by the API. However, the default retry strategy can be overridden on a per-operation basis, or across the entire SDK.\n\nTo change the default retry strategy for a single API call, simply provide an `Options` object built with a `RetryConfig` object to the call:\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Operations;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Shared;\nuse Speakeasy\\SpeakeasyClientSDK\\Utils\\Retry;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()\n    -\u003esetSecurity(\n        new Shared\\Security(\n            apiKey: '\u003cYOUR_API_KEY_HERE\u003e',\n        )\n    )\n    -\u003ebuild();\n\n$request = new Operations\\GetWorkspaceAccessRequest();\n\n$response = $sdk-\u003eauth-\u003egetAccess(\n    request: $request,\n    options: Utils\\Options-\u003ebuilder()-\u003esetRetryConfig(\n        new Retry\\RetryConfigBackoff(\n            initialInterval: 1,\n            maxInterval:     50,\n            exponent:        1.1,\n            maxElapsedTime:  100,\n            retryConnectionErrors: false,\n        ))-\u003ebuild()\n);\n\nif ($response-\u003eaccessDetails !== null) {\n    // handle response\n}\n```\n\nIf you'd like to override the default retry strategy for all operations that support retries, you can pass a `RetryConfig` object to the `SDKBuilder-\u003esetRetryConfig` function when initializing the SDK:\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Operations;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Shared;\nuse Speakeasy\\SpeakeasyClientSDK\\Utils\\Retry;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()\n    -\u003esetRetryConfig(\n        new Retry\\RetryConfigBackoff(\n            initialInterval: 1,\n            maxInterval:     50,\n            exponent:        1.1,\n            maxElapsedTime:  100,\n            retryConnectionErrors: false,\n        )\n  )\n    -\u003esetSecurity(\n        new Shared\\Security(\n            apiKey: '\u003cYOUR_API_KEY_HERE\u003e',\n        )\n    )\n    -\u003ebuild();\n\n$request = new Operations\\GetWorkspaceAccessRequest();\n\n$response = $sdk-\u003eauth-\u003egetAccess(\n    request: $request\n);\n\nif ($response-\u003eaccessDetails !== null) {\n    // handle response\n}\n```\n\u003c!-- End Retries [retries] --\u003e\n\n\u003c!-- Start Error Handling [errors] --\u003e\n## Error Handling\n\nHandling errors in this SDK should largely match your expectations. All operations return a response object or throw an exception.\n\nBy default an API error will raise a `Errorors\\SDKExceptioon` exception, which has the following properties:\n\n| Property       | Type                                    | Description           |\n|----------------|-----------------------------------------|-----------------------|\n| `$message`     | *string*                                | The error message     |\n| `$statusCode`  | *int*                                   | The HTTP status code  |\n| `$rawResponse` | *?\\Psr\\Http\\Message\\ResponseInterface*  | The raw HTTP response |\n| `$body`        | *string*                                | The response content  |\n\nWhen custom error responses are specified for an operation, the SDK may also throw their associated exception. You can refer to respective *Errors* tables in SDK docs for more details on possible exception types for each operation. For example, the `createRemoteSource` method throws the following exceptions:\n\n| Error Type             | Status Code | Content Type     |\n| ---------------------- | ----------- | ---------------- |\n| Errorors\\Error         | 4XX         | application/json |\n| Errorors\\SDKExceptioon | 5XX         | \\*/\\*            |\n\n### Example\n\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Errorors;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Shared;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()\n    -\u003esetSecurity(\n        new Shared\\Security(\n            apiKey: '\u003cYOUR_API_KEY_HERE\u003e',\n        )\n    )\n    -\u003ebuild();\n\ntry {\n    $request = new Shared\\RemoteSource(\n        inputs: [\n            new Shared\\RemoteDocument(\n                registryUrl: 'https://productive-swine.net',\n            ),\n        ],\n        output: new Shared\\RemoteDocument(\n            registryUrl: 'https://spiteful-apricot.info',\n        ),\n    );\n\n    $response = $sdk-\u003eartifacts-\u003ecreateRemoteSource(\n        request: $request\n    );\n\n    if ($response-\u003estatusCode === 200) {\n        // handle response\n    }\n} catch (Errorors\\ErrorThrowable $e) {\n    // handle $e-\u003e$container data\n    throw $e;\n} catch (Errorors\\SDKExceptioon $e) {\n    // handle default exception\n    throw $e;\n}\n```\n\u003c!-- End Error Handling [errors] --\u003e\n\n\u003c!-- Start Server Selection [server] --\u003e\n## Server Selection\n\n### Select Server by Name\n\nYou can override the default server globally using the `setServer(string $serverName)` builder method when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the names associated with the available servers:\n\n| Name   | Server                           | Description |\n| ------ | -------------------------------- | ----------- |\n| `prod` | `https://api.prod.speakeasy.com` |             |\n\n#### Example\n\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Shared;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()\n    -\u003esetServer('prod')\n    -\u003esetSecurity(\n        new Shared\\Security(\n            apiKey: '\u003cYOUR_API_KEY_HERE\u003e',\n        )\n    )\n    -\u003ebuild();\n\n$request = new Shared\\RemoteSource(\n    inputs: [\n        new Shared\\RemoteDocument(\n            registryUrl: 'https://productive-swine.net',\n        ),\n    ],\n    output: new Shared\\RemoteDocument(\n        registryUrl: 'https://spiteful-apricot.info',\n    ),\n);\n\n$response = $sdk-\u003eartifacts-\u003ecreateRemoteSource(\n    request: $request\n);\n\nif ($response-\u003estatusCode === 200) {\n    // handle response\n}\n```\n\n### Override Server URL Per-Client\n\nThe default server can also be overridden globally using the `setServerUrl(string $serverUrl)` builder method when initializing the SDK client instance. For example:\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Speakeasy\\SpeakeasyClientSDK;\nuse Speakeasy\\SpeakeasyClientSDK\\Models\\Shared;\n\n$sdk = SpeakeasyClientSDK\\SDK::builder()\n    -\u003esetServerURL('https://api.prod.speakeasy.com')\n    -\u003esetSecurity(\n        new Shared\\Security(\n            apiKey: '\u003cYOUR_API_KEY_HERE\u003e',\n        )\n    )\n    -\u003ebuild();\n\n$request = new Shared\\RemoteSource(\n    inputs: [\n        new Shared\\RemoteDocument(\n            registryUrl: 'https://productive-swine.net',\n        ),\n    ],\n    output: new Shared\\RemoteDocument(\n        registryUrl: 'https://spiteful-apricot.info',\n    ),\n);\n\n$response = $sdk-\u003eartifacts-\u003ecreateRemoteSource(\n    request: $request\n);\n\nif ($response-\u003estatusCode === 200) {\n    // handle response\n}\n```\n\u003c!-- End Server Selection [server] --\u003e\n\n\u003c!-- Start Summary [summary] --\u003e\n## Summary\n\nSpeakeasy API: The Subscriptions API manages subscriptions for CLI and registry events\n\nFor more information about the API: [The Speakeasy Platform Documentation](/docs)\n\u003c!-- End Summary [summary] --\u003e\n\n\u003c!-- Start Table of Contents [toc] --\u003e\n## Table of Contents\n\u003c!-- $toc-max-depth=2 --\u003e\n* [speakeasy-api/speakeasy-client-sdk-php](#speakeasy-apispeakeasy-client-sdk-php)\n  * [SDK Installation](#sdk-installation)\n  * [SDK Example Usage](#sdk-example-usage)\n  * [Authentication](#authentication)\n  * [Available Resources and Operations](#available-resources-and-operations)\n  * [Global Parameters](#global-parameters)\n  * [Retries](#retries)\n  * [Error Handling](#error-handling)\n  * [Server Selection](#server-selection)\n\n\u003c!-- End Table of Contents [toc] --\u003e\n\n\u003c!-- Placeholder for Future Speakeasy SDK Sections --\u003e\n\n\n\n### Maturity\n\nThis SDK is in beta, and there may be breaking changes between versions without a major version update. Therefore, we recommend pinning usage\nto a specific package version. This way, you can install the same version each time without breaking changes unless you are intentionally\nlooking for the latest version.\n\n### Contributions\n\nWhile we value open-source contributions to this SDK, this library is generated programmatically.\nFeel free to open a PR or a Github issue as a proof of concept and we'll do our best to include it in a future release !\n\n### SDK Created by [Speakeasy](https://docs.speakeasyapi.dev/docs/using-speakeasy/client-sdks)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspeakeasy-api%2Fspeakeasy-client-sdk-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspeakeasy-api%2Fspeakeasy-client-sdk-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspeakeasy-api%2Fspeakeasy-client-sdk-php/lists"}