import requests
url = "https://eu.app.clarifeye.ai/api/v1/organizations/{id}/provision-user/"
payload = {
"email": "[email protected]",
"role": "member"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({email: '[email protected]', role: 'member'})
};
fetch('https://eu.app.clarifeye.ai/api/v1/organizations/{id}/provision-user/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://eu.app.clarifeye.ai/api/v1/organizations/{id}/provision-user/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"email": "[email protected]",
"role": "member"
}
'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"email": "[email protected]",
"role": "member",
"created": true
}{
"error": "User not found"
}{
"error": "User not found"
}Pre-create (or re-activate) an org user
Pre-creates a user bound to this organization, with a verified primary email so a
later SSO login links to it automatically. Idempotent: re-provisioning an existing
member is a no-op (role/state unchanged). The email’s domain must be in the org’s
allowed_provisioning_domains. The API key must belong to the organization in the path.
Service accounts cannot be provisioned (400): they are managed on the organization’s
Service accounts page.
import requests
url = "https://eu.app.clarifeye.ai/api/v1/organizations/{id}/provision-user/"
payload = {
"email": "[email protected]",
"role": "member"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({email: '[email protected]', role: 'member'})
};
fetch('https://eu.app.clarifeye.ai/api/v1/organizations/{id}/provision-user/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://eu.app.clarifeye.ai/api/v1/organizations/{id}/provision-user/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"email": "[email protected]",
"role": "member"
}
'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"email": "[email protected]",
"role": "member",
"created": true
}{
"error": "User not found"
}{
"error": "User not found"
}Authorizations
Use Authorization: Bearer <token>. The token is either a user token / OAuth access
token, or a service-account API key (cfk_...). A key is valid on every endpoint and
acts as its service account, an organization member with per-store permissions.
Refused keys answer 403 with Invalid API key., API key revoked.,
API key expired. or API key disabled..
Path Parameters
UUID of the organization (must match the API key's org)