Skip to navigation

Create a new key

Create a new key of the type specified by the type parameter. If a name is not supplied, one will be auto generated.

Authentication

Authorizationstring

This key is used for all apis with the exception of ingest. You can obtain it following these instructions and placing the key in the header of your call in the format of Authorization: Token {accesstoken} For example:

curl -H 'Authorization: Token <ACCESS TOKEN>'
OR
servicekeystring

(Deprecated) This key is used for v1 and v2 apis with the exception of ingest. Service keys can be used by placing your service key in the Authorization header of your api call. NOTE Usage of the service key auth mechanism has been deprecated in favor of IAM Access Tokens. Service keys can no longer be created, but can still be used for v1 and v2 apis while the transition takes place

Query parameters

typeenumRequired
The type of key to be created
Allowed values:

Request

Modifiable fields can be set in the request body.
namestringOptional<=30 characters
A user friendly name for the key

Response

A new key was created successfully! The entire key resource is returned.
idstringOptional
The ID of the key
keystringOptional
A secret key which can be used to authenticate requests to Mezmo.
namestringOptional<=30 characters
A user friendly name for the key
typeenumOptional
The type of the key
Allowed values:
createdintegerOptional
The time the key was created as a Unix timestamp in milliseconds

Errors

400
Bad Request Error