Organization
Create role
POST
/
role
Create role
curl --request POST \
--url https://{instance}/api/v2/role \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"name": "<string>",
"description": "<string>",
"permissions": [
"<string>"
],
"permissionsV2": [
{}
]
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
permissions: ['<string>'],
permissionsV2: [{}]
})
};
fetch('https://{instance}/api/v2/role', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{instance}/api/v2/role"
payload = {
"name": "<string>",
"description": "<string>",
"permissions": ["<string>"],
"permissionsV2": [{}]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)⌘I
Create role
curl --request POST \
--url https://{instance}/api/v2/role \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"name": "<string>",
"description": "<string>",
"permissions": [
"<string>"
],
"permissionsV2": [
{}
]
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
permissions: ['<string>'],
permissionsV2: [{}]
})
};
fetch('https://{instance}/api/v2/role', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{instance}/api/v2/role"
payload = {
"name": "<string>",
"description": "<string>",
"permissions": ["<string>"],
"permissionsV2": [{}]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)