---
title: "Connect a tool"
url: https://xovris.ai/docs/api/operations/posttoolconnections/
---

# Connect a tool

`POST /v1/tool-connections`

Needs a token that can read and change. A token without change access is refused with `token_read_only` and the step to take.

## Request body

### `application/json`

- `tool`
- `purpose` (string)
- `settings` (object)
- `credentials` (object)
- `baseUrl`
- `goal` (string)
- `domain` (string)
- `description` (string)
- `credential`
- `direction`
- `senderKey` (string)
- `sender` (string)

Example:

```json
{
  "tool": null,
  "purpose": "string",
  "settings": {},
  "credentials": {},
  "baseUrl": null,
  "goal": "string",
  "domain": "string",
  "description": "string",
  "credential": null,
  "direction": null,
  "senderKey": "string",
  "sender": "string"
}
```

## Answers

- `201`: Done: something new was made, and the answer is it. (application/json: T800365b3e3f2 | T947c24288126 | Tb1a479a9c69b | T97b07afc4fdf | Tb74b25142f94 | T3359436c79a5 | T34d96c3e197d | T889ad1c74aa2 | Te939b9c5ea89 | T3c8ca91fccda | Tb5bfc1e3ca06 | T30f5967bbd32 | T55a84d1ced54 | T9f96019396f1)
- `202`: Started: the answer says where to follow it. (application/json: T84fe83dbe3f4 | T990b8fab6ccf | T4afffb155596)
- `401`: Not signed in: the token is missing, expired or revoked. The answer says how to get a new one. (application/json: Problem)
- `403`: Signed in, but this token or role may not do this. The answer names the permission it needs. (application/json: Problem)
- `404`: Nothing with that id here, or it belongs to another workspace. Nothing was changed. (application/json: Problem)
- `default`: Any other refusal or failure. The answer says what happened and what to do next. (application/json: Problem)

## A call

The address is https://api.xovris.ai/v1/tool-connections - put your own value in place of each part in braces.

```sh
curl --request POST \
  --url 'https://api.xovris.ai/v1/tool-connections' \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{"tool":null,"purpose":"string","settings":{},"credentials":{},"baseUrl":null,"goal":"string","domain":"string","description":"string","credential":null,"direction":null,"senderKey":"string","sender":"string"}'
```
