The documentation for this SDK lives at platform.claude.com/docs/en/api/sdks/php. To suggest changes, open an issue.
This repository uses Composer for dependency management.
To set up the repository, run:
$ composer installOr use the bootstrap script:
$ ./scripts/bootstrapMost of the SDK is generated code. Modifications to code will be persisted between generations, but may
result in merge conflicts between manual patches and changes from the generator. The generator will never
modify the contents of the examples/ directory.
All files in the examples/ directory are not modified by the generator and can be freely edited or added to.
Most tests require you to set up a mock server against the OpenAPI spec to run the tests.
$ npx prism mock path/to/your/openapi.yml$ ./scripts/testThis repository uses PHPStan for static analysis and PHP CS Fixer for formatting.
To lint:
$ ./scripts/lintTo format:
$ ./scripts/formatChanges made to this repository via the automated release PR pipeline should publish to Packagist automatically. If the changes aren't made through the automated pipeline, you may want to make releases manually.