Channels

Embed
Preview of the card
<a href="https://indrava.forumulate.com/docs/ref-channels"><img src="https://indrava.forumulate.com/docs/_api/public/orgs/e421ace4-3e78-4ed8-9818-7b4899cf3aa0/spaces/2bcc7f09-4489-40af-85d8-9fdd3f3da314/pages/4567b683-eed7-495b-8b15-33131f19154d/social-card.svg?v=3e7ae33eec8b" alt="Channels" width="600" height="315"></a>
GET http://localhost:4000/api/v1/channels/providers

List the platforms Indrava can post to

Code samples

cURL
curl -X GET "http://localhost:4000/api/v1/channels/providers"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
GET http://localhost:4000/api/v1/channels

List connected channels

Parameters

clientId
string
query

Code samples

cURL
curl -X GET "http://localhost:4000/api/v1/channels" \
  -H "Authorization: Bearer $API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
[
  {
    "id": "string",
    "provider": "string",
    "name": "string",
    "handle": "string",
    "avatarUrl": "string",
    "status": "active",
    "clientId": "string"
  }
]
Schema
id
string
required
provider
string
required
name
string
required
handle
string
required
avatarUrl
string
required
status
string
required
active | needs_reauth | disabled
clientId
string
required
GET http://localhost:4000/api/v1/channels/{id}

Get one channel with its platform's rules

The channel, and what its platform accepts: text limit, media rules, post settings, and what parts after the first become.

Parameters

id
string
path
required

Code samples

cURL
curl -X GET "http://localhost:4000/api/v1/channels/{id}" \
  -H "Authorization: Bearer $API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
DELETE http://localhost:4000/api/v1/channels/{id}

Remove a channel

Also revokes Indrava's access at the platform where the platform allows it.

Parameters

id
string
path
required

Code samples

cURL
curl -X DELETE "http://localhost:4000/api/v1/channels/{id}" \
  -H "Authorization: Bearer $API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
PATCH http://localhost:4000/api/v1/channels/{id}

Give a channel a display name of your own

name: null goes back to the platform's name.

Parameters

id
string
path
required

Request body

application/json
name
string
required
{
  "name": "string"
}

Code samples

cURL
curl -X PATCH "http://localhost:4000/api/v1/channels/{id}" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
GET http://localhost:4000/api/v1/channels/{channelId}/options

List the choices of a live settings field

For settings fields marked live (boards, playlists, communities): the values the platform offers this channel. Send query for fields marked search, and the form's other values as settings when the field has dependsOn.

Parameters

channelId
string
path
required
field
string
query
required
query
string
query
settings
object
query
= {}

Code samples

cURL
curl -X GET "http://localhost:4000/api/v1/channels/{channelId}/options?field=<field>" \
  -H "Authorization: Bearer $API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
POST http://localhost:4000/api/v1/channels/connect

Connect a channel with credential fields

For platforms whose connect is fields in GET /channels/providers: send the connectFields as credentials. Connecting the same account again replaces its credentials. Other platforms sign in: use POST /channels/oauth/start.

Request body

application/json
provider
string
required
credentials
object
required
{
  "provider": "string",
  "credentials": {}
}

Code samples

cURL
curl -X POST "http://localhost:4000/api/v1/channels/connect" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"provider":"string","credentials":{}}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
PUT http://localhost:4000/api/v1/channels/{id}/credentials

Replace the credentials of a channel that connects with fields

For a rotated token or a changed password. The channel keeps its posts and settings; credentials of another account are refused.

Parameters

id
string
path
required

Request body

application/json
credentials
object
required
{
  "credentials": {}
}

Code samples

cURL
curl -X PUT "http://localhost:4000/api/v1/channels/{id}/credentials" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"credentials":{}}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
POST http://localhost:4000/api/v1/channels/{id}/disable

Pause a channel

It keeps its posts and settings; posts that come due skip it.

Parameters

id
string
path
required

Request body

application/json
reason
string
{
  "reason": "string"
}

Code samples

cURL
curl -X POST "http://localhost:4000/api/v1/channels/{id}/disable" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"reason":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
POST http://localhost:4000/api/v1/channels/{id}/enable

Resume a paused channel

Answers 402 when the plan already runs as many channels as it allows.

Parameters

id
string
path
required

Code samples

cURL
curl -X POST "http://localhost:4000/api/v1/channels/{id}/enable" \
  -H "Authorization: Bearer $API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
GET http://localhost:4000/api/v1/channels/{id}/impact

What removing or pausing a channel touches

scheduled posts are waiting to go to it; alone of them go nowhere else. Ask before DELETE /channels/{id}.

Parameters

id
string
path
required

Code samples

cURL
curl -X GET "http://localhost:4000/api/v1/channels/{id}/impact" \
  -H "Authorization: Bearer $API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
PUT http://localhost:4000/api/v1/channels/{id}/preferences

Save a channel's own preferences

The channelFields of its platform, from GET /channels/{id}.

Parameters

id
string
path
required

Request body

application/json
settings
object
required
{
  "settings": {}
}

Code samples

cURL
curl -X PUT "http://localhost:4000/api/v1/channels/{id}/preferences" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"settings":{}}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
POST http://localhost:4000/api/v1/channels/oauth/start

Get the sign-in URL that connects a channel on an OAuth platform

Open url in a browser. After consent the browser lands on the app's Channels screen, which finishes the connection for a signed-in admin; or call POST /channels/oauth/complete with connectionId yourself.

Request body

application/json
provider
string
required
fields
object
= {}
{
  "provider": "string",
  "fields": {}
}

Code samples

cURL
curl -X POST "http://localhost:4000/api/v1/channels/oauth/start" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"provider":"string","fields":{}}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}
POST http://localhost:4000/api/v1/channels/oauth/complete

Finish an OAuth connection after the sign-in

Saves the channel when the sign-in covers one account. With several (pages, organisations) the answer lists them: call again with the chosen remoteIds.

Request body

application/json
connectionId
string
required
remoteIds
string[]
{
  "connectionId": "string",
  "remoteIds": [
    "string"
  ]
}

Code samples

cURL
curl -X POST "http://localhost:4000/api/v1/channels/oauth/complete" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"connectionId":"string","remoteIds":["string"]}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 OK
Example
{}
Option 1
{}
Option 2
{}

Updated