alrayyes / hush-hush
Official PHP SDK for hush-hush, generated from its OpenAPI spec
v3.4.9
2026-09-05 11:17 UTC
Requires
- php: >=8.2
- guzzlehttp/guzzle: 7.15.5
- psr/http-client: 1.0.3
- psr/http-factory: 1.1.0
Requires (Dev)
- ergebnis/composer-normalize: 2.52.0
- friendsofphp/php-cs-fixer: 3.95.23
- infection/infection: 0.35.3
- league/uri: 7.5.1
- league/uri-interfaces: 7.8.1
- pact-foundation/pact-php: 10.2.1
- phpdocumentor/phpdocumentor: 3.10.0
- phpmd/phpmd: 2.15.0
- phpstan/phpstan: 2.2.12
- phpunit/phpunit: 13.3.2
- rector/rector: 2.6.5
- roave/security-advisories: dev-latest
- squizlabs/php_codesniffer: 4.0.4
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
The official PHP SDK for hush-hush, generated from its OpenAPI spec and kept in sync with it automatically.
Install
composer require alrayyes/hush-hush
Requires PHP 8.2 or newer.
Quickstart
use HushHush\Client; $client = new Client('https://hush-hush.example.com', 'your-api-key'); // or set HUSH_HUSH_API_KEY // Create is a write operation — it needs the credential above. $client->createObject('my-first-secret', 'already-sealed-ciphertext'); // Get needs no credential — hush-hush's confidentiality boundary is // "who holds a matching private key," not who's calling this endpoint. $value = $client->getObject('my-first-secret'); echo 'got ' . strlen($value) . " bytes of sealed ciphertext\n"; // The audit log records every read and write; querying it needs no // credential either, and returns the full matching result set (there's // no pagination on this endpoint). foreach ($client->queryAuditLog() as $entry) { echo $entry->getAction() . ' ' . $entry->getObjectId() . ' ' . $entry->getTimestamp()->format(DATE_ATOM) . "\n"; }
The API key is only required for write operations (create/update/delete);
reads (get, used-by, audit-log query) work without one. A per-call $caller
argument, accepted by create/get/update/delete, is optional. See the
full API reference for
everything else.
Versioning
This SDK's version tracks hush-hush's OpenAPI spec, not this repo's own commit history — see CONTRIBUTING.md for how a spec change becomes a release.