Mailmus

API keys

GET
/projects/{projectId}/api-keys

Path Parameters

projectId*string

Response Body

application/json

curl -X GET "https://example.com/projects/string/api-keys"
[  {    "id": "string",    "name": "string",    "type": "SECRET",    "environment": "LIVE",    "key": "mailmus_publishable_key_live_...",    "lastUsedAt": "2019-08-24T14:15:22Z",    "createdAt": "2019-08-24T14:15:22Z"  }]
POST
/projects/{projectId}/api-keys

Path Parameters

projectId*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/projects/string/api-keys" \  -H "Content-Type: application/json" \  -d '{    "name": "Production key",    "type": "SECRET"  }'
{  "id": "string",  "name": "string",  "type": "SECRET",  "environment": "LIVE",  "lastUsedAt": "2019-08-24T14:15:22Z",  "createdAt": "2019-08-24T14:15:22Z",  "key": "mailmus_secret_key_live_..."}
DELETE
/projects/{projectId}/api-keys/{id}

Path Parameters

id*string
projectId*string

Response Body

application/json

curl -X DELETE "https://example.com/projects/string/api-keys/string"
{  "id": "string",  "name": "string",  "type": "SECRET",  "environment": "LIVE",  "key": "mailmus_publishable_key_live_...",  "lastUsedAt": "2019-08-24T14:15:22Z",  "createdAt": "2019-08-24T14:15:22Z"}