======================================================
This module is an PHP API client for Design Atoms API which is a part of Customer's Canvas web-to-print system. It is supposed that you are familiar with its services and understand how to use its APIs. To learn more about Customer's Canvas and its services, refer the Getting Started section of its documentation.
To be able to use this package, you need to meet the following requirements:
- You must have an account at Customer's Canvas.
For other platforms, see the Backend services article in Customer's Canvas documentation.
composer require aurigma/design-atoms-api-client
PHP 7.4 and later.
To install the bindings via Composer, add the following to composer.json:
{
"require": {
"aurigma/design-atoms-api-client": "*@dev"
}
}Then run composer install
Please follow the installation procedure.
Receive an access token through your backend as explained in the documentation and deliver it to your app.
Then run the following:
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: ApiKey
$config = Aurigma\DesignAtoms\Configuration::getDefaultConfiguration()->setApiKey('X-API-Key', 'YOUR_API_KEY');
// Configure OAuth2 access token for authorization: OAuth2ClientCredentials
$config = Aurigma\DesignAtoms\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
$apiInstance = new Aurigma\DesignAtoms\Api\BuildInfoApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client()
);
try {
$result = $apiInstance->buildInfoGetInfo();
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling BuildInfoApi->buildInfoGetInfo: ', $e->getMessage(), PHP_EOL;
}
?>Aurigma Inc info@aurigma.com (https://customerscanvas.com)