light-mode-image
Learn

API Reference

Create a Custom domain

POST/v1/config/domain

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Request Body

The custom domain payload

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

curl -X POST "https://example.com/v1/config/domain" \  -H "Content-Type: application/json" \  -d '{    "name": "Example Corp",    "logoUrl": "https://cdn.example.com/logo.jpg",    "domain": "example.com"  }'
{  "name": "Example Corp",  "logoUrl": "https://cdn.example.com/logo.jpg",  "domain": "example.com",  "verificationToken": "8c6f36c1-91ff-439d-a518-48cf7ef421ef",  "isVerified": false}

Retrieve Custom domain

GET/v1/config/domain

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Response Body

application/json

application/json

curl -X GET "https://example.com/v1/config/domain"
{  "name": "Example Corp",  "logoUrl": "https://cdn.example.com/logo.icon",  "domain": "example.com",  "verificationToken": "8c6f36c1-91ff-439d-a518-48cf7ef421ef",  "isVerified": true,  "verifiedAt": "2024-01-31T20:31:48.340Z"}

Update Custom domain

PUT/v1/config/domain

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

curl -X PUT "https://example.com/v1/config/domain" \  -H "Content-Type: application/json" \  -d '{    "name": "Example Corp",    "logoUrl": "https://cdn.example.com/logo.jpg",    "domain": "example.com"  }'
{  "name": "Example Corp",  "logoUrl": "https://cdn.example.com/logo.icon",  "domain": "example.com",  "verificationToken": "8c6f36c1-91ff-439d-a518-48cf7ef421ef",  "isVerified": true,  "verifiedAt": "2021-04-15T07:37:25.008Z"}

Delete Custom domain

DELETE/v1/config/domain

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X DELETE "https://example.com/v1/config/domain"
Empty

Verify Custom domain

POST/v1/config/domain/verify

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Response Body

application/json

application/json

curl -X POST "https://example.com/v1/config/domain/verify"
Empty

How would you rate this page?

Last updated on

On this page