Maestro Content API (2.0.0)

Download OpenAPI specification:Download

Maestro Content API documentation provides instructions on how to authenticate against the API's and perform CRUD operations against site objects

Introduction

Maestro defines its APIs using the OpenAPI 3.0 specifications (formally Swagger). These specs can be downloaded and used to generate client sdks in your prefered language. (see "Code Generation" section) In order to start using the API's you must first authenticate by POSTing to the auth/v2/login endpoint (see "Authentication" section).

Important Note

You are required to pass a header with key "x-maestro-client-id", the value of which is your APIKey's "Maestro Id", for every API request you make, including when obtaining a JWT.

Authentication

JWT

JWT Token received from auth/v2/login endpoint. You may obtain a token by POSTing your APIKey to /auth/v2/login.
eg:

curl -XPOST api.maestro.io/auth/v2/login \
-H 'Content-Type: application/json' \
-H 'x-maestro-client-id: YOUR_CLIENT_ID' \
-d '{"apikey": "YOUR_API_KEY"}'

Security Scheme Type HTTP
HTTP Authorization Scheme bearer
Bearer format "JWT"

StreamProviderAuthorization

UUID v4 that is created and returned when a Stream Provider first registers through streamprovider/v1/register.

Security Scheme Type HTTP
HTTP Authorization Scheme bearer
Bearer format "UUIDv4"

AccessCode

Perform RESTful operations on AccessCode

Add an access code to a specific site

Authorizations:
header Parameters
x-maestro-client-id
required
string

Your maestro id

Request Body schema: application/json

Request body to create an access code

accessCode
required
string

Actual access code to be used

accountId
string

Account Id of Maestro Account

siteId
required
string

Maestro Id associated with site

sku
string

Subscription SKU

type
required
string (TAccessCodeType)
Enum: "subscription" "login"

Access code type

Responses

Response Schema: application/json
accessCode
required
string

Actual access code to be used

accountId
string

Account Id of Maestro Account

siteId
required
string

Maestro Id associated with site

sku
string

Subscription SKU

type
required
string (TAccessCodeType)
Enum: "subscription" "login"

Access code type

Request samples

Content type
application/json
{
  • "accessCode": "string",
  • "accountId": "string",
  • "siteId": "string",
  • "sku": "string",
  • "type": "subscription"
}

Response samples

Content type
application/json
Example
{
  • "accessCode": "ABCD-EFGH",
  • "siteId": "YOUR_MAESTRO_SITE_ID",
  • "sku": "EXAMPLE-SKU",
  • "type": "subscription"
}

Get specific access code based on id

Authorizations:
path Parameters
id
required
string

Id of the access code to return

header Parameters
x-maestro-client-id
required
string

Your maestro id

Responses

Response Schema: application/json
accessCode
required
string

Actual access code to be used

accountId
string

Account Id of Maestro Account

siteId
required
string

Maestro Id associated with site

sku
string

Subscription SKU

type
required
string (TAccessCodeType)
Enum: "subscription" "login"

Access code type

Request samples

const axios = require('axios');
const headers = {
  authorization: 'YOUR_JWT_TOKEN',
  ['x-maestro-client-id']: 'YOUR_MAESTRO_ID'
};

axios.get('https://api.maestro.io/accesscode/v1/{ACCESSCODE_ID}', { headers })
  .then((response) => {
    console.log(respo