Add a domain
curl --request POST \
--url https://my.orq.ai/v2/{workspace_key}/domains \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"domain": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({domain: '<string>'})
};
fetch('https://my.orq.ai/v2/{workspace_key}/domains', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://my.orq.ai/v2/{workspace_key}/domains"
payload = { "domain": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"domain": {
"id": "<string>",
"domain": "<string>",
"status": "DOMAIN_VERIFICATION_STATUS_UNSPECIFIED",
"txt_name": "<string>",
"txt_value": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"expires_at": "2023-11-07T05:31:56Z",
"verified_at": "2023-11-07T05:31:56Z",
"created_by_id": "<string>"
}
}Workspace Security
Add a domain
Creates a domain-verification challenge and returns the TXT record to add to DNS.
POST
/
v2
/
{workspace_key}
/
domains
Add a domain
curl --request POST \
--url https://my.orq.ai/v2/{workspace_key}/domains \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"domain": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({domain: '<string>'})
};
fetch('https://my.orq.ai/v2/{workspace_key}/domains', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://my.orq.ai/v2/{workspace_key}/domains"
payload = { "domain": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"domain": {
"id": "<string>",
"domain": "<string>",
"status": "DOMAIN_VERIFICATION_STATUS_UNSPECIFIED",
"txt_name": "<string>",
"txt_value": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"expires_at": "2023-11-07T05:31:56Z",
"verified_at": "2023-11-07T05:31:56Z",
"created_by_id": "<string>"
}
}Was this page helpful?