{"id":21412617,"url":"https://github.com/worksome/sdk-php","last_synced_at":"2026-01-20T05:33:05.315Z","repository":{"id":63944825,"uuid":"542669138","full_name":"worksome/sdk-php","owner":"worksome","description":"An object-oriented PHP wrapper for the Worksome API","archived":false,"fork":false,"pushed_at":"2025-04-17T10:37:43.000Z","size":46,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-06-23T07:43:01.679Z","etag":null,"topics":["api","client","graphql","php","worksome","wrapper"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/worksome.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE.md","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},"funding":{"github":"worksome"}},"created_at":"2022-09-28T15:48:10.000Z","updated_at":"2025-04-17T10:35:02.000Z","dependencies_parsed_at":"2024-03-12T16:30:44.464Z","dependency_job_id":"6aaa3253-a4a3-4abd-ac65-27949c1b7f2d","html_url":"https://github.com/worksome/sdk-php","commit_stats":{"total_commits":18,"total_committers":1,"mean_commits":18.0,"dds":0.0,"last_synced_commit":"58187b14b33434cc87ccd1771d80bd4b5fdab855"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/worksome/sdk-php","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/worksome%2Fsdk-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/worksome%2Fsdk-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/worksome%2Fsdk-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/worksome%2Fsdk-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/worksome","download_url":"https://codeload.github.com/worksome/sdk-php/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/worksome%2Fsdk-php/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265233753,"owners_count":23731825,"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":["api","client","graphql","php","worksome","wrapper"],"created_at":"2024-11-22T18:14:47.619Z","updated_at":"2026-01-20T05:33:05.310Z","avatar_url":"https://github.com/worksome.png","language":"PHP","funding_links":["https://github.com/sponsors/worksome"],"categories":[],"sub_categories":[],"readme":"# Worksome PHP SDK\n\n[![Latest Version on Packagist][ico-version]][link-packagist]\n[![Software License][ico-license]](LICENSE.md)\n[![Build Status][ico-github-actions]][link-github-actions]\n[![Static Analysis Status][ico-static-analysis]][link-static-analysis]\n[![Total Downloads][ico-downloads]][link-downloads]\n\nAn object-oriented PHP wrapper for the Worksome API\n\n## Requirements\n\n- PHP \u003e= 8.4\n- A [PSR-17 implementation](https://packagist.org/providers/psr/http-factory-implementation)\n- A [PSR-18 implementation](https://packagist.org/providers/psr/http-client-implementation)\n\n## Install\n\nVia Composer\n\n```shell\ncomposer require worksome/sdk guzzlehttp/guzzle:^7.5 http-interop/http-factory-guzzle:^1.2\n```\n\nWe are decoupled from any HTTP messaging client with help by [HTTPlug](https://httplug.io).\n\n## Usage\n\n#### Basic usage\n\n```php\n// Include the Composer autoloader\nrequire_once __DIR__ . '/vendor/autoload.php';\n\n$client = new \\Worksome\\Sdk\\Client();\n$repositories = $client-\u003egraph()-\u003eexecute(\u003c\u003c\u003cGQL\n    query {\n        profile {\n            name\n            email\n        }\n    }\n\u003e\u003e\u003e);\n```\n\n#### Authentication\n\nThe Worksome SDK supports authenticating through an API token.\n\n```php\n$client = new \\Worksome\\Sdk\\Client();\n$client-\u003eauthenticate($apiToken);\n```\n\n#### Using a different base URI\n\nThe Worksome SDK defaults to using the `https://api.worksome.com` URI, however if a custom URI is required, this can be passed to the constructor:\n\n```php\n$client = new \\Worksome\\Sdk\\Client(baseUri: 'https://api.local');\n```\n\n#### Using a different HTTP client\n\nThanks to [HTTPlug](https://httplug.io), we support the use of many HTTP clients. For example, to use the Symfony HTTP\nClient, first install the client and PSR-7 implementation.\n\n```shell\ncomposer require worksome/sdk symfony/http-client nyholm/psr7\n```\n\nNext, set up the Worksome client with this HTTP client:\n\n```php\n$client = \\Worksome\\SDK\\Client::createWithHttpClient(\n    new \\Symfony\\Component\\HttpClient\\HttplugClient()\n);\n```\n\nAlternatively, you can inject an HTTP client through the `Client` constructor.\n\n## Change log\n\nPlease see [GitHub Releases](https://github.com/worksome/sdk-php/releases) for more information on what has changed recently.\n\n## Testing\n\n```shell\ncomposer test\n```\n\nTo update the test snapshots, set the `WORKSOME_LOCAL_API_URL` and `WORKSOME_LOCAL_API_TOKEN` environment variables, and\nthen run `composer update:snapshots`.\n\n## Credits\n\n- [Owen Voke][link-author]\n- [All Contributors][link-contributors]\n\n## License\n\nThe MIT License (MIT). Please see [License File](LICENSE.md) for more information.\n\n[ico-version]: https://img.shields.io/packagist/v/worksome/sdk.svg?style=flat-square\n[ico-license]: https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square\n[ico-github-actions]: https://img.shields.io/github/actions/workflow/status/worksome/sdk-php/tests.yml?branch=main\u0026label=tests\u0026style=flat-square\n[ico-static-analysis]: https://img.shields.io/github/actions/workflow/status/worksome/sdk-php/static.yml?branch=main\u0026label=static%20analysis\u0026style=flat-square\n[ico-downloads]: https://img.shields.io/packagist/dt/worksome/sdk.svg?style=flat-square\n\n[link-packagist]: https://packagist.org/packages/worksome/sdk\n[link-github-actions]: https://github.com/worksome/sdk-php/actions\n[link-static-analysis]: https://github.com/worksome/sdk-php/actions?query=workflow%3AStatic%20Analysis\n[link-downloads]: https://packagist.org/packages/worksome/sdk\n[link-author]: https://github.com/owenvoke\n[link-contributors]: ../../contributors\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fworksome%2Fsdk-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fworksome%2Fsdk-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fworksome%2Fsdk-php/lists"}