Accounts
Tokens
Tokens endpoint reference.
List
List all Account Owned API tokens created for this account.
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
accountId | string | Yes | Account identifier. | |
params | array | No | [] | Array containing the necessary params. |
php
$response = $client->accounts()->tokens()->list('ACCOUNT_ID', []);
Create
Create a new Account Owned API token.
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
accountId | string | Yes | Account identifier. | |
values | array | Yes | Token values, requires name and policies. |
php
$response = $client->accounts()->tokens()->create('ACCOUNT_ID', []);
Get
Get information about a specific Account Owned API token.
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
accountId | string | Yes | Account identifier. | |
tokenId | string | Yes | Token identifier. |
php
$response = $client->accounts()->tokens()->get('ACCOUNT_ID', 'TOKEN_ID');
Update
Update an existing token.
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
accountId | string | Yes | Account identifier. | |
tokenId | string | Yes | Token identifier. | |
values | array | Yes | Token values, e.g. name, policies, condition, status. |
php
$response = $client->accounts()->tokens()->update('ACCOUNT_ID', 'TOKEN_ID', []);
Delete
Destroy an Account Owned API token.
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
accountId | string | Yes | Account identifier. | |
tokenId | string | Yes | Token identifier. |
php
$response = $client->accounts()->tokens()->delete('ACCOUNT_ID', 'TOKEN_ID');
Verify
Test whether a token works.
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
accountId | string | Yes | Account identifier. |
php
$response = $client->accounts()->tokens()->verify('ACCOUNT_ID');

