Agents

Delete agent

Remove an agent for good.

DELETEhttps://app.elunos.ai/api/v1/spaces/{space}/agents/{agent}

Deletes an agent. If a phone number is still assigned to it, the API refuses with 409 referenced. Assign the number to another agent in the platform first.

Path parameters

spacestringPflicht

Slug of the space, e.g. `praxis-mueller`. Returned by `GET /spaces`.

agentuuidPflicht

ID of the agent.

Query parameters

expected_updated_atdatetime

`updated_at` from your last read. If the stored value differs, the API answers 409 `stale` with the current record instead of overwriting someone else's change.

Example

curl -X DELETE https://app.elunos.ai/api/v1/spaces/praxis-mueller/agents/0199a3c2-7d4e-7b21-9f3a-2c5e8d1b4a70 \
  -H "Authorization: Bearer np_xxxxxxxx"

Response

On success the deleted resource in data. If something still refers to it:

{
  "code": "referenced",
  "message": "The agent is still assigned to a phone number.",
  "references": [
    {
      "type": "phone_number",
      "id": "0199a3e1-…",
      "name": "+49 221 123456"
    }
  ]
}

The agent's conversations are kept. This cannot be undone.