API

AddressSetup

A link where a workspace member creates a Telegram bot or a Slack app for an agent with the provider.

Operations

Every route this entity exposes. Each route links to its own reference on this page.

Method Route SDK operation Returns
POST /agents/{id}/addresses/setups create The link

Examples

One example per SDK, generated from the API model. The argument names are the parameters and fields of this entity, and the values are placeholders. The examples are not compiled or executed.

Golang

Construct client as shown in the Golang setup, then call the operations:

created, err := client.AddressSetup(nil).Create(map[string]any{"agent_id": "example", "channel": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(created)

Lua

Construct client as shown in the Lua setup, then call the operations:

local created, err = client:AddressSetup():create({ agent_id = "example", channel = "example" })

PHP

Construct client as shown in the PHP setup, then call the operations:

$created = $client->AddressSetup()->create(["agent_id" => "example", "channel" => "example"]);

Python

Construct client as shown in the Python setup, then call the operations:

created = client.AddressSetup().create({ "agent_id": "example", "channel": "example" })

Ruby

Construct client as shown in the Ruby setup, then call the operations:

created = client.AddressSetup.create({ "agent_id" => "example", "channel" => "example" })

TypeScript

Construct client as shown in the TypeScript setup, then call the operations:

const created = await client.AddressSetup().create({ agent_id: "example", channel: "example" })

Fields

Field Type Required Description
channel string Yes Channel
token string No What installs an app the member made: a Slack app's client id, client secret and signing secret, in that order, with spaces between.

create

POST /agents/{id}/addresses/setups

Operation ID: setUpAddress.

Authentication: bearer token (token) or oauth2 (oauth).

Parameters

Parameter In Type Required Description
id path string Yes The agent's id

Request body

application/json

Property Type Required Description
channel enum: email, sms, telegram, slack Yes
token string No What installs an app the member made: a Slack app's client id, client secret and signing secret, in that order, with spaces between. The link is then the provider's consent page, which sends the member back to the agent's page with setup and code for addAddress.

Responses

application/json

Property Type Required Description
url string Yes Where the member creates the address, such as a link to Artil's Telegram bot or to a Slack app made from Artil's manifest
4XX: The request failed; the error says why

application/json

Property Type Required Description
error object Yes
error.code enum: invalid_input, unauthorized, forbidden, plan_limit, not_found, conflict, ... Yes
error.message string Yes
5XX: The request failed; the error says why

application/json

Property Type Required Description
error object Yes
error.code enum: invalid_input, unauthorized, forbidden, plan_limit, not_found, conflict, ... Yes
error.message string Yes