Skip to main content
POST
/
agents
Create a new Agent
curl --request POST \
  --url https://commerce.driv.ly/api/agents \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "<string>",
  "id": "<string>",
  "prompt": "<string>",
  "functions": [
    "<string>"
  ]
}
'
{
  "data": {
    "id": "<string>",
    "model": "<string>",
    "prompt": "<string>",
    "functions": [
      "<string>"
    ]
  },
  "success": true
}

Query Parameters

depth
integer

The number of levels of related objects to include in the response

Body

application/json
model
string
required

Agent has Agent Model

id
string

Agent is uniquely identified by id

prompt
string

Agent has Prompt

functions
string[]

Agent has Function

Response

Agent Created

data
Agent · object
Example:
{
"id": "ai_3jks93ndk3s9",
"model": "gpt-4o",
"prompt": "Respond to the customer service request",
"functions": ["fnc_ed904md03684"]
}
success
boolean