Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
cURL
curl --request POST \ --url https://api.agentpowers.ai/v1/auth/api-tokens \ --header 'Content-Type: application/json' \ --data ' { "name": "Default" } '
import requestsurl = "https://api.agentpowers.ai/v1/auth/api-tokens"payload = { "name": "Default" }headers = {"Content-Type": "application/json"}response = requests.post(url, json=payload, headers=headers)print(response.text)
const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: JSON.stringify({name: 'Default'})};fetch('https://api.agentpowers.ai/v1/auth/api-tokens', options) .then(res => res.json()) .then(res => console.log(res)) .catch(err => console.error(err));
{ "token": "<string>", "name": "<string>", "created_at": "<string>", "expires_at": "<string>" }
{ "detail": [ { "loc": [ "<string>" ], "msg": "<string>", "type": "<string>", "input": "<unknown>", "ctx": {} } ]}
Create a new API token. The full token is returned only once.
64
Successful Response
Was this page helpful?