API Reference

All API requests require a valid Corporate Merch API Token.

Generate API Tokens

API Tokens can be generated via the Corporate Merch dashboard under Developers > API Tokens.

API URL

The API endpoints can be consumed using the API URL: https://api.corporatemerch.com/v1/

Authentication

Our API require a valid Token that should be sent using the Authorization header (Bearer).

curl --request GET \
     --url https://api.corporatemerch.com/v1/products \
     --header 'Accept: application/json' \
     --header 'Authorization: Bearer API_Token'
const options = {
  method: 'GET',
  headers: {Accept: 'application/json', Authorization: 'Bearer API_Token'}
};

fetch('https://api.corporatemerch.com/v1/products', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.corporatemerch.com/v1/products', [
  'headers' => [
    'Accept' => 'application/json',
    'Authorization' => 'Bearer API_Token',
  ],
]);

echo $response->getBody();