Create Demo Domain

Description

Create a new demo domain. Demo domains expires after a given trial period.

Request

POST /v1/demo-domains
{
  tags?: {
    [key: string]: string
  }
}

Response

Successful response contains the following JSON formated body:

{
  domain: string,
  organizationId: string,
  tags: {
    [key: string]: string
  },
  allowSelfSigned: boolean,
  created: string,
  currentBatchId: number,
  expiresAt: string,
  deleted: boolean
}

Response Status codes:

  • 200 on success

Request headers

This request must have the following headers:

  • Authorization: bearer <ApiKey>
  • X-Nabto-Organization: <organizationId>
  • Content-Type: application/json

Example

Request

curl -XPOST "https://api.cloud.nabto.com/v1/demo-domains" \
  -H "Authorization: Bearer <ApiKey>" \
  -H "X-Nabto-Organization: <OrganizationId>" \
  -H "Content-Type: application/json" \
  -d '{ tags: {"foo": "bar" }}'

Response

{
   domain: "mydomain.example.net",
  organizationId: "or-lmnopqrs",
  tags: {
    "foo": "bar" 
  },
  allowSelfSigned: true,
  created: "2022-10-18T10:17:24.299Z",
  currentBatchId: 42,
  expiresAt: "2022-10-18T10:17:24.299Z",
  deleted: true
}