{"id":28825184,"url":"https://github.com/polarsource/polar-php","last_synced_at":"2026-04-03T08:03:24.139Z","repository":{"id":268896038,"uuid":"905785737","full_name":"polarsource/polar-php","owner":"polarsource","description":"Polar SDK for PHP","archived":false,"fork":false,"pushed_at":"2026-03-28T00:29:26.000Z","size":3240,"stargazers_count":41,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2026-03-28T17:34:12.018Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://docs.polar.sh/developers/sdk","language":"PHP","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/polarsource.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":null,"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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-12-19T14:16:15.000Z","updated_at":"2026-03-28T08:37:58.000Z","dependencies_parsed_at":"2025-04-05T01:20:20.209Z","dependency_job_id":"0e168dc7-695f-4fda-a7b7-77ece35c8e35","html_url":"https://github.com/polarsource/polar-php","commit_stats":null,"previous_names":["polarsource/polar-php"],"tags_count":42,"template":false,"template_full_name":null,"purl":"pkg:github/polarsource/polar-php","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polarsource%2Fpolar-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polarsource%2Fpolar-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polarsource%2Fpolar-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polarsource%2Fpolar-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/polarsource","download_url":"https://codeload.github.com/polarsource/polar-php/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polarsource%2Fpolar-php/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31342746,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-03T06:57:30.245Z","status":"ssl_error","status_checked_at":"2026-04-03T06:57:29.849Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":"2025-06-19T01:43:26.630Z","updated_at":"2026-04-03T08:03:24.132Z","avatar_url":"https://github.com/polarsource.png","language":"PHP","funding_links":["https://polar.sh/docs/api-reference","https://api.polar.sh","https://sandbox-api.polar.sh"],"categories":[],"sub_categories":[],"readme":"# polar-sh/sdk\n\nDeveloper-friendly \u0026 type-safe Php SDK specifically catered to leverage *polar-sh/sdk* API.\n\n\u003cdiv align=\"left\"\u003e\n    \u003ca href=\"https://www.speakeasy.com/?utm_source=polar-sh/sdk\u0026utm_campaign=php\"\u003e\u003cimg src=\"https://custom-icon-badges.demolab.com/badge/-Built%20By%20Speakeasy-212015?style=for-the-badge\u0026logoColor=FBE331\u0026logo=speakeasy\u0026labelColor=545454\" /\u003e\u003c/a\u003e\n    \u003ca href=\"https://opensource.org/licenses/MIT\"\u003e\n        \u003cimg src=\"https://img.shields.io/badge/License-MIT-blue.svg\" style=\"width: 100px; height: 28px;\" /\u003e\n    \u003c/a\u003e\n\u003c/div\u003e\n\n\n\u003cbr /\u003e\u003cbr /\u003e\n\u003e [!IMPORTANT]\n\u003e This SDK is not yet ready for production use. To complete setup please follow the steps outlined in your [workspace](https://app.speakeasy.com/org/polar/polar). Delete this section before \u003e publishing to a package manager.\n\n\u003c!-- Start Summary [summary] --\u003e\n## Summary\n\nPolar API: Polar HTTP and Webhooks API\n\nRead the docs at https://polar.sh/docs/api-reference\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* [polar-sh/sdk](#polar-shsdk)\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  * [Pagination](#pagination)\n  * [Error Handling](#error-handling)\n  * [Server Selection](#server-selection)\n* [Development](#development)\n  * [Maturity](#maturity)\n  * [Contributions](#contributions)\n\n\u003c!-- End Table of Contents [toc] --\u003e\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 \"polar-sh/sdk\"\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 Polar;\n\n$sdk = Polar\\Polar::builder()\n    -\u003esetSecurity(\n        '\u003cYOUR_BEARER_TOKEN_HERE\u003e'\n    )\n    -\u003ebuild();\n\n\n\n$responses = $sdk-\u003eorganizations-\u003elist(\n    page: 1,\n    limit: 10\n\n);\n\n\nforeach ($responses as $response) {\n    if ($response-\u003estatusCode === 200) {\n        // handle response\n    }\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 scheme globally:\n\n| Name          | Type | Scheme      |\n| ------------- | ---- | ----------- |\n| `accessToken` | http | HTTP Bearer |\n\nTo authenticate with the API the `accessToken` parameter must be set when initializing the SDK. For example:\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Polar;\n\n$sdk = Polar\\Polar::builder()\n    -\u003esetSecurity(\n        '\u003cYOUR_BEARER_TOKEN_HERE\u003e'\n    )\n    -\u003ebuild();\n\n\n\n$responses = $sdk-\u003eorganizations-\u003elist(\n    page: 1,\n    limit: 10\n\n);\n\n\nforeach ($responses as $response) {\n    if ($response-\u003estatusCode === 200) {\n        // handle response\n    }\n}\n```\n\n### Per-Operation Security Schemes\n\nSome operations in this SDK require the security scheme to be specified at the request level. For example:\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Polar;\nuse Polar\\Models\\Operations;\n\n$sdk = Polar\\Polar::builder()-\u003ebuild();\n\n$request = new Operations\\CustomerPortalBenefitGrantsListRequest();\n$requestSecurity = new Operations\\CustomerPortalBenefitGrantsListSecurity(\n    customerSession: '\u003cYOUR_BEARER_TOKEN_HERE\u003e',\n);\n\n$responses = $sdk-\u003ecustomerPortal-\u003ebenefitGrants-\u003elist(\n    request: $request,\n    security: $requestSecurity\n);\n\n\nforeach ($responses as $response) {\n    if ($response-\u003estatusCode === 200) {\n        // handle response\n    }\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### [BenefitGrants](docs/sdks/benefitgrants/README.md)\n\n* [list](docs/sdks/benefitgrants/README.md#list) - List Benefit Grants\n\n### [Benefits](docs/sdks/benefits/README.md)\n\n* [list](docs/sdks/benefits/README.md#list) - List Benefits\n* [create](docs/sdks/benefits/README.md#create) - Create Benefit\n* [get](docs/sdks/benefits/README.md#get) - Get Benefit\n* [delete](docs/sdks/benefits/README.md#delete) - Delete Benefit\n* [update](docs/sdks/benefits/README.md#update) - Update Benefit\n* [grants](docs/sdks/benefits/README.md#grants) - List Benefit Grants\n\n### [CheckoutLinks](docs/sdks/checkoutlinks/README.md)\n\n* [list](docs/sdks/checkoutlinks/README.md#list) - List Checkout Links\n* [create](docs/sdks/checkoutlinks/README.md#create) - Create Checkout Link\n* [get](docs/sdks/checkoutlinks/README.md#get) - Get Checkout Link\n* [delete](docs/sdks/checkoutlinks/README.md#delete) - Delete Checkout Link\n* [update](docs/sdks/checkoutlinks/README.md#update) - Update Checkout Link\n\n### [Checkouts](docs/sdks/checkouts/README.md)\n\n* [list](docs/sdks/checkouts/README.md#list) - List Checkout Sessions\n* [create](docs/sdks/checkouts/README.md#create) - Create Checkout Session\n* [get](docs/sdks/checkouts/README.md#get) - Get Checkout Session\n* [update](docs/sdks/checkouts/README.md#update) - Update Checkout Session\n* [clientGet](docs/sdks/checkouts/README.md#clientget) - Get Checkout Session from Client\n* [clientUpdate](docs/sdks/checkouts/README.md#clientupdate) - Update Checkout Session from Client\n* [clientConfirm](docs/sdks/checkouts/README.md#clientconfirm) - Confirm Checkout Session from Client\n\n### [CustomFields](docs/sdks/customfields/README.md)\n\n* [list](docs/sdks/customfields/README.md#list) - List Custom Fields\n* [create](docs/sdks/customfields/README.md#create) - Create Custom Field\n* [get](docs/sdks/customfields/README.md#get) - Get Custom Field\n* [delete](docs/sdks/customfields/README.md#delete) - Delete Custom Field\n* [update](docs/sdks/customfields/README.md#update) - Update Custom Field\n\n### [CustomerMeters](docs/sdks/customermeters/README.md)\n\n* [list](docs/sdks/customermeters/README.md#list) - List Customer Meters\n* [get](docs/sdks/customermeters/README.md#get) - Get Customer Meter\n\n### [CustomerPortal.BenefitGrants](docs/sdks/polarbenefitgrants/README.md)\n\n* [list](docs/sdks/polarbenefitgrants/README.md#list) - List Benefit Grants\n* [get](docs/sdks/polarbenefitgrants/README.md#get) - Get Benefit Grant\n* [update](docs/sdks/polarbenefitgrants/README.md#update) - Update Benefit Grant\n\n### [CustomerPortal.CustomerMeters](docs/sdks/polarcustomermeters/README.md)\n\n* [list](docs/sdks/polarcustomermeters/README.md#list) - List Meters\n* [get](docs/sdks/polarcustomermeters/README.md#get) - Get Customer Meter\n\n### [CustomerPortal.CustomerSession](docs/sdks/customersession/README.md)\n\n* [introspect](docs/sdks/customersession/README.md#introspect) - Introspect Customer Session\n* [getAuthenticatedUser](docs/sdks/customersession/README.md#getauthenticateduser) - Get Authenticated Portal User\n\n### [CustomerPortal.Customers](docs/sdks/polarcustomers/README.md)\n\n* [get](docs/sdks/polarcustomers/README.md#get) - Get Customer\n* [update](docs/sdks/polarcustomers/README.md#update) - Update Customer\n* [listPaymentMethods](docs/sdks/polarcustomers/README.md#listpaymentmethods) - List Customer Payment Methods\n* [addPaymentMethod](docs/sdks/polarcustomers/README.md#addpaymentmethod) - Add Customer Payment Method\n* [confirmPaymentMethod](docs/sdks/polarcustomers/README.md#confirmpaymentmethod) - Confirm Customer Payment Method\n* [deletePaymentMethod](docs/sdks/polarcustomers/README.md#deletepaymentmethod) - Delete Customer Payment Method\n\n### [CustomerPortal.Downloadables](docs/sdks/downloadables/README.md)\n\n* [list](docs/sdks/downloadables/README.md#list) - List Downloadables\n\n### [CustomerPortal.LicenseKeys](docs/sdks/polarlicensekeys/README.md)\n\n* [list](docs/sdks/polarlicensekeys/README.md#list) - List License Keys\n* [get](docs/sdks/polarlicensekeys/README.md#get) - Get License Key\n* [validate](docs/sdks/polarlicensekeys/README.md#validate) - Validate License Key\n* [activate](docs/sdks/polarlicensekeys/README.md#activate) - Activate License Key\n* [deactivate](docs/sdks/polarlicensekeys/README.md#deactivate) - Deactivate License Key\n\n### [CustomerPortal.Members](docs/sdks/polarmembers/README.md)\n\n* [listMembers](docs/sdks/polarmembers/README.md#listmembers) - List Members\n* [addMember](docs/sdks/polarmembers/README.md#addmember) - Add Member\n* [removeMember](docs/sdks/polarmembers/README.md#removemember) - Remove Member\n* [updateMember](docs/sdks/polarmembers/README.md#updatemember) - Update Member\n\n### [CustomerPortal.Orders](docs/sdks/polarorders/README.md)\n\n* [list](docs/sdks/polarorders/README.md#list) - List Orders\n* [get](docs/sdks/polarorders/README.md#get) - Get Order\n* [update](docs/sdks/polarorders/README.md#update) - Update Order\n* [invoice](docs/sdks/polarorders/README.md#invoice) - Get Order Invoice\n* [generateInvoice](docs/sdks/polarorders/README.md#generateinvoice) - Generate Order Invoice\n* [getPaymentStatus](docs/sdks/polarorders/README.md#getpaymentstatus) - Get Order Payment Status\n* [confirmRetryPayment](docs/sdks/polarorders/README.md#confirmretrypayment) - Confirm Retry Payment\n\n### [CustomerPortal.Organizations](docs/sdks/polarorganizations/README.md)\n\n* [get](docs/sdks/polarorganizations/README.md#get) - Get Organization\n\n### [CustomerPortal.Seats](docs/sdks/seats/README.md)\n\n* [listSeats](docs/sdks/seats/README.md#listseats) - List Seats\n* [assignSeat](docs/sdks/seats/README.md#assignseat) - Assign Seat\n* [revokeSeat](docs/sdks/seats/README.md#revokeseat) - Revoke Seat\n* [resendInvitation](docs/sdks/seats/README.md#resendinvitation) - Resend Invitation\n* [listClaimedSubscriptions](docs/sdks/seats/README.md#listclaimedsubscriptions) - List Claimed Subscriptions\n\n### [CustomerPortal.Subscriptions](docs/sdks/polarsubscriptions/README.md)\n\n* [list](docs/sdks/polarsubscriptions/README.md#list) - List Subscriptions\n* [get](docs/sdks/polarsubscriptions/README.md#get) - Get Subscription\n* [cancel](docs/sdks/polarsubscriptions/README.md#cancel) - Cancel Subscription\n* [update](docs/sdks/polarsubscriptions/README.md#update) - Update Subscription\n\n### [CustomerPortal.Wallets](docs/sdks/wallets/README.md)\n\n* [list](docs/sdks/wallets/README.md#list) - List Wallets\n* [get](docs/sdks/wallets/README.md#get) - Get Wallet\n\n### [CustomerSeats](docs/sdks/customerseats/README.md)\n\n* [listSeats](docs/sdks/customerseats/README.md#listseats) - List Seats\n* [assignSeat](docs/sdks/customerseats/README.md#assignseat) - Assign Seat\n* [revokeSeat](docs/sdks/customerseats/README.md#revokeseat) - Revoke Seat\n* [resendInvitation](docs/sdks/customerseats/README.md#resendinvitation) - Resend Invitation\n* [getClaimInfo](docs/sdks/customerseats/README.md#getclaiminfo) - Get Claim Info\n* [claimSeat](docs/sdks/customerseats/README.md#claimseat) - Claim Seat\n\n### [CustomerSessions](docs/sdks/customersessions/README.md)\n\n* [create](docs/sdks/customersessions/README.md#create) - Create Customer Session\n\n### [Customers](docs/sdks/customers/README.md)\n\n* [list](docs/sdks/customers/README.md#list) - List Customers\n* [create](docs/sdks/customers/README.md#create) - Create Customer\n* [export](docs/sdks/customers/README.md#export) - Export Customers\n* [get](docs/sdks/customers/README.md#get) - Get Customer\n* [delete](docs/sdks/customers/README.md#delete) - Delete Customer\n* [update](docs/sdks/customers/README.md#update) - Update Customer\n* [getExternal](docs/sdks/customers/README.md#getexternal) - Get Customer by External ID\n* [deleteExternal](docs/sdks/customers/README.md#deleteexternal) - Delete Customer by External ID\n* [updateExternal](docs/sdks/customers/README.md#updateexternal) - Update Customer by External ID\n* [getState](docs/sdks/customers/README.md#getstate) - Get Customer State\n* [getStateExternal](docs/sdks/customers/README.md#getstateexternal) - Get Customer State by External ID\n\n### [Discounts](docs/sdks/discounts/README.md)\n\n* [list](docs/sdks/discounts/README.md#list) - List Discounts\n* [create](docs/sdks/discounts/README.md#create) - Create Discount\n* [get](docs/sdks/discounts/README.md#get) - Get Discount\n* [delete](docs/sdks/discounts/README.md#delete) - Delete Discount\n* [update](docs/sdks/discounts/README.md#update) - Update Discount\n\n### [Disputes](docs/sdks/disputes/README.md)\n\n* [list](docs/sdks/disputes/README.md#list) - List Disputes\n* [get](docs/sdks/disputes/README.md#get) - Get Dispute\n\n### [EventTypes](docs/sdks/eventtypes/README.md)\n\n* [list](docs/sdks/eventtypes/README.md#list) - List Event Types\n* [update](docs/sdks/eventtypes/README.md#update) - Update Event Type\n\n### [Events](docs/sdks/events/README.md)\n\n* [list](docs/sdks/events/README.md#list) - List Events\n* [listNames](docs/sdks/events/README.md#listnames) - List Event Names\n* [get](docs/sdks/events/README.md#get) - Get Event\n* [ingest](docs/sdks/events/README.md#ingest) - Ingest Events\n\n### [Files](docs/sdks/files/README.md)\n\n* [list](docs/sdks/files/README.md#list) - List Files\n* [create](docs/sdks/files/README.md#create) - Create File\n* [uploaded](docs/sdks/files/README.md#uploaded) - Complete File Upload\n* [delete](docs/sdks/files/README.md#delete) - Delete File\n* [update](docs/sdks/files/README.md#update) - Update File\n\n### [LicenseKeys](docs/sdks/licensekeys/README.md)\n\n* [list](docs/sdks/licensekeys/README.md#list) - List License Keys\n* [get](docs/sdks/licensekeys/README.md#get) - Get License Key\n* [update](docs/sdks/licensekeys/README.md#update) - Update License Key\n* [getActivation](docs/sdks/licensekeys/README.md#getactivation) - Get Activation\n* [validate](docs/sdks/licensekeys/README.md#validate) - Validate License Key\n* [activate](docs/sdks/licensekeys/README.md#activate) - Activate License Key\n* [deactivate](docs/sdks/licensekeys/README.md#deactivate) - Deactivate License Key\n\n### [Members](docs/sdks/members/README.md)\n\n* [listMembers](docs/sdks/members/README.md#listmembers) - List Members\n* [createMember](docs/sdks/members/README.md#createmember) - Create Member\n* [getMember](docs/sdks/members/README.md#getmember) - Get Member\n* [deleteMember](docs/sdks/members/README.md#deletemember) - Delete Member\n* [updateMember](docs/sdks/members/README.md#updatemember) - Update Member\n\n### [Meters](docs/sdks/meters/README.md)\n\n* [list](docs/sdks/meters/README.md#list) - List Meters\n* [create](docs/sdks/meters/README.md#create) - Create Meter\n* [get](docs/sdks/meters/README.md#get) - Get Meter\n* [update](docs/sdks/meters/README.md#update) - Update Meter\n* [quantities](docs/sdks/meters/README.md#quantities) - Get Meter Quantities\n\n### [Metrics](docs/sdks/metrics/README.md)\n\n* [get](docs/sdks/metrics/README.md#get) - Get Metrics\n* [limits](docs/sdks/metrics/README.md#limits) - Get Metrics Limits\n* [listDashboards](docs/sdks/metrics/README.md#listdashboards) - List Metric Dashboards\n* [createDashboard](docs/sdks/metrics/README.md#createdashboard) - Create Metric Dashboard\n* [getDashboard](docs/sdks/metrics/README.md#getdashboard) - Get Metric Dashboard\n* [deleteDashboard](docs/sdks/metrics/README.md#deletedashboard) - Delete Metric Dashboard\n* [updateDashboard](docs/sdks/metrics/README.md#updatedashboard) - Update Metric Dashboard\n\n### [Oauth2](docs/sdks/oauth2/README.md)\n\n* [authorize](docs/sdks/oauth2/README.md#authorize) - Authorize\n* [token](docs/sdks/oauth2/README.md#token) - Request Token\n* [revoke](docs/sdks/oauth2/README.md#revoke) - Revoke Token\n* [introspect](docs/sdks/oauth2/README.md#introspect) - Introspect Token\n* [userinfo](docs/sdks/oauth2/README.md#userinfo) - Get User Info\n\n#### [Oauth2.Clients](docs/sdks/clients/README.md)\n\n* [create](docs/sdks/clients/README.md#create) - Create Client\n* [get](docs/sdks/clients/README.md#get) - Get Client\n* [update](docs/sdks/clients/README.md#update) - Update Client\n* [delete](docs/sdks/clients/README.md#delete) - Delete Client\n\n### [Orders](docs/sdks/orders/README.md)\n\n* [list](docs/sdks/orders/README.md#list) - List Orders\n* [export](docs/sdks/orders/README.md#export) - Export Orders\n* [get](docs/sdks/orders/README.md#get) - Get Order\n* [update](docs/sdks/orders/README.md#update) - Update Order\n* [invoice](docs/sdks/orders/README.md#invoice) - Get Order Invoice\n* [generateInvoice](docs/sdks/orders/README.md#generateinvoice) - Generate Order Invoice\n\n### [OrganizationAccessTokens](docs/sdks/organizationaccesstokens/README.md)\n\n* [list](docs/sdks/organizationaccesstokens/README.md#list) - List\n* [create](docs/sdks/organizationaccesstokens/README.md#create) - Create\n* [delete](docs/sdks/organizationaccesstokens/README.md#delete) - Delete\n* [update](docs/sdks/organizationaccesstokens/README.md#update) - Update\n\n### [Organizations](docs/sdks/organizations/README.md)\n\n* [list](docs/sdks/organizations/README.md#list) - List Organizations\n* [create](docs/sdks/organizations/README.md#create) - Create Organization\n* [get](docs/sdks/organizations/README.md#get) - Get Organization\n* [update](docs/sdks/organizations/README.md#update) - Update Organization\n\n### [Payments](docs/sdks/payments/README.md)\n\n* [list](docs/sdks/payments/README.md#list) - List Payments\n* [get](docs/sdks/payments/README.md#get) - Get Payment\n\n### [Products](docs/sdks/products/README.md)\n\n* [list](docs/sdks/products/README.md#list) - List Products\n* [create](docs/sdks/products/README.md#create) - Create Product\n* [get](docs/sdks/products/README.md#get) - Get Product\n* [update](docs/sdks/products/README.md#update) - Update Product\n* [updateBenefits](docs/sdks/products/README.md#updatebenefits) - Update Product Benefits\n\n### [Refunds](docs/sdks/refunds/README.md)\n\n* [list](docs/sdks/refunds/README.md#list) - List Refunds\n* [create](docs/sdks/refunds/README.md#create) - Create Refund\n\n### [Subscriptions](docs/sdks/subscriptions/README.md)\n\n* [list](docs/sdks/subscriptions/README.md#list) - List Subscriptions\n* [create](docs/sdks/subscriptions/README.md#create) - Create Subscription\n* [export](docs/sdks/subscriptions/README.md#export) - Export Subscriptions\n* [get](docs/sdks/subscriptions/README.md#get) - Get Subscription\n* [revoke](docs/sdks/subscriptions/README.md#revoke) - Revoke Subscription\n* [update](docs/sdks/subscriptions/README.md#update) - Update Subscription\n\n### [Webhooks](docs/sdks/webhooks/README.md)\n\n* [listWebhookEndpoints](docs/sdks/webhooks/README.md#listwebhookendpoints) - List Webhook Endpoints\n* [createWebhookEndpoint](docs/sdks/webhooks/README.md#createwebhookendpoint) - Create Webhook Endpoint\n* [getWebhookEndpoint](docs/sdks/webhooks/README.md#getwebhookendpoint) - Get Webhook Endpoint\n* [deleteWebhookEndpoint](docs/sdks/webhooks/README.md#deletewebhookendpoint) - Delete Webhook Endpoint\n* [updateWebhookEndpoint](docs/sdks/webhooks/README.md#updatewebhookendpoint) - Update Webhook Endpoint\n* [resetWebhookEndpointSecret](docs/sdks/webhooks/README.md#resetwebhookendpointsecret) - Reset Webhook Endpoint Secret\n* [listWebhookDeliveries](docs/sdks/webhooks/README.md#listwebhookdeliveries) - List Webhook Deliveries\n* [redeliverWebhookEvent](docs/sdks/webhooks/README.md#redeliverwebhookevent) - Redeliver Webhook Event\n\n\u003c/details\u003e\n\u003c!-- End Available Resources and Operations [operations] --\u003e\n\n\u003c!-- Start Pagination [pagination] --\u003e\n## Pagination\n\nSome of the endpoints in this SDK support pagination. To use pagination, you make your SDK calls as usual, but the\nreturned object will be a `Generator` instead of an individual response.\n\nWorking with generators is as simple as iterating over the responses in a `foreach` loop, and you can see an example below:\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Polar;\n\n$sdk = Polar\\Polar::builder()\n    -\u003esetSecurity(\n        '\u003cYOUR_BEARER_TOKEN_HERE\u003e'\n    )\n    -\u003ebuild();\n\n\n\n$responses = $sdk-\u003eorganizations-\u003elist(\n    page: 1,\n    limit: 10\n\n);\n\n\nforeach ($responses as $response) {\n    if ($response-\u003estatusCode === 200) {\n        // handle response\n    }\n}\n```\n\u003c!-- End Pagination [pagination] --\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 `Errors\\APIException` 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 `list` method throws the following exceptions:\n\n| Error Type                 | Status Code | Content Type     |\n| -------------------------- | ----------- | ---------------- |\n| Errors\\HTTPValidationError | 422         | application/json |\n| Errors\\APIException        | 4XX, 5XX    | \\*/\\*            |\n\n### Example\n\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Polar;\nuse Polar\\Models\\Errors;\n\n$sdk = Polar\\Polar::builder()\n    -\u003esetSecurity(\n        '\u003cYOUR_BEARER_TOKEN_HERE\u003e'\n    )\n    -\u003ebuild();\n\ntry {\n    $responses = $sdk-\u003eorganizations-\u003elist(\n        page: 1,\n        limit: 10\n\n    );\n\n    foreach ($responses as $response) {\n        if ($response-\u003estatusCode === 200) {\n            // handle response\n        }\n    }\n} catch (Errors\\HTTPValidationErrorThrowable $e) {\n    // handle $e-\u003e$container data\n    throw $e;\n} catch (Errors\\APIException $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| `production` | `https://api.polar.sh`         | Production environment |\n| `sandbox`    | `https://sandbox-api.polar.sh` | Sandbox environment    |\n\n#### Example\n\n```php\ndeclare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Polar;\n\n$sdk = Polar\\Polar::builder()\n    -\u003esetServer('production')\n    -\u003esetSecurity(\n        '\u003cYOUR_BEARER_TOKEN_HERE\u003e'\n    )\n    -\u003ebuild();\n\n\n\n$responses = $sdk-\u003eorganizations-\u003elist(\n    page: 1,\n    limit: 10\n\n);\n\n\nforeach ($responses as $response) {\n    if ($response-\u003estatusCode === 200) {\n        // handle response\n    }\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 Polar;\n\n$sdk = Polar\\Polar::builder()\n    -\u003esetServerURL('https://api.polar.sh')\n    -\u003esetSecurity(\n        '\u003cYOUR_BEARER_TOKEN_HERE\u003e'\n    )\n    -\u003ebuild();\n\n\n\n$responses = $sdk-\u003eorganizations-\u003elist(\n    page: 1,\n    limit: 10\n\n);\n\n\nforeach ($responses as $response) {\n    if ($response-\u003estatusCode === 200) {\n        // handle response\n    }\n}\n```\n\u003c!-- End Server Selection [server] --\u003e\n\n\u003c!-- Placeholder for Future Speakeasy SDK Sections --\u003e\n\n# Development\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. Any manual changes added to internal files will be overwritten on the next generation. \nWe look forward to hearing your feedback. Feel free to open a PR or an issue with a proof of concept and we'll do our best to include it in a future release. \n\n### SDK Created by [Speakeasy](https://www.speakeasy.com/?utm_source=polar-sh/sdk\u0026utm_campaign=php)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpolarsource%2Fpolar-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpolarsource%2Fpolar-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpolarsource%2Fpolar-php/lists"}