hacocms / hacocms-php-sdk
hacoCMS PHP SDK
v1.0.2
2023-04-19 07:42 UTC
Requires
- ext-json: *
- guzzlehttp/guzzle: 7.*
Requires (Dev)
- phpunit/phpunit: ^9.5
README
Install
$ composer require hacocms/hacocms-php-sdk
Usage
Call list api
- リスト形式APIのコール
$client = new HacoCMS\V1\HacoCMSApiClient('subdomain', 'access_token'); // https://[subdomain].hacocms.com/api/v1/[endpoint] $res = $client->list('endpoint');
Call listSingleContent api
- リスト形式APIのコール
- (リスト内の単一コンテンツを取得する)
$client = new HacoCMS\V1\HacoCMSApiClient('subdomain', 'access_token'); // https://[subdomain].hacocms.com/api/v1/[endpoint]/[content_id] $res = $client->listSingleContent('endpoint', 'content_id');
Call single api.
- シングル形式APIのコール
$client = new HacoCMS\V1\HacoCMSApiClient('subdomain', 'access_token'); // https://[subdomain].hacocms.com/api/v1/[endpoint] $res = $client->single('endpoint');
ライセンス
MIT License