• Authentication/
    Application Keys/
    Create an Application Key

    Create an Application Key

    POST Create an Application Key

    https://api.moltin.com/v2/application-keys
    

    Parameters

    Headers

    NameRequiredTypeDescription
    AuthorizationRequiredstringThe Bearer token required to get access to the API.

    Body

    NameRequiredTypeDescription
    typeRequiredstringAlways application_key.
    nameRequiredstringThe name of the application key to be created.

    Request Example - Curl

    curl -X POST https://api.moltin.com/v2/application-keys \
         -H "Authorization: Bearer XXXX"
         -H "Content-Type: application/json" \
         -d $'{
           "data":
           {
            "type": "application_key",
            "name": "Test keys"
          }
    }'
    

    Response Example

    201 Created

    {
        "data": {
            "id": "2a0949f6-661b-4a19-b0ed-e97b41e98623",
            "name": "Test keys",
            "type": "application_key",
            "client_id": "d4fcc576f661778c29fcd7b78461da8291cc6b003d",
            "client_secret": "8c52f85e3d6915e76f97139bdd71780f4ce0a8f13a",
            "meta": {
                "timestamps": {
                    "last_used_at": "2022-08-24T19:53:52.474283337Z",
                    "created_at": "2022-08-24T19:53:52.474283337Z",
                    "updated_at": "2022-08-24T19:53:52.474283337Z"
                }
            }
        },
        "links": {
            "self": "https://api.moltin.com/v2/application-keys/2a0949f6-661b-4a19-b0ed-e97b41e98623"
        }
    }
    

    Was this helpful?

    Previous
    Get an Application Key