Create a service account
curl --request POST \
--url https://api.arg.ai/api/service-accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"organization_id": "<string>",
"name": "<string>"
}
'import requests
url = "https://api.arg.ai/api/service-accounts"
payload = {
"organization_id": "<string>",
"name": "<string>"
}
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({organization_id: '<string>', name: '<string>'})
};
fetch('https://api.arg.ai/api/service-accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{}{
"detail": "<string>"
}API Keys
Create a service account
Create a non-human identity to own API keys. You cannot assign it a role above your own.
POST
/
api
/
service-accounts
Create a service account
curl --request POST \
--url https://api.arg.ai/api/service-accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"organization_id": "<string>",
"name": "<string>"
}
'import requests
url = "https://api.arg.ai/api/service-accounts"
payload = {
"organization_id": "<string>",
"name": "<string>"
}
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({organization_id: '<string>', name: '<string>'})
};
fetch('https://api.arg.ai/api/service-accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{}{
"detail": "<string>"
}Authorizations
bearerAuthapiKeyAuth
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Response
Successful response
The response is of type object.