SoulFire LogoSoulFire

Set bot desired state

Persists whether the selected bots should be running or stopped. The request returns after the desired state is durable. Connections are reconciled asynchronously and can be observed through WatchBotStatuses.

POST
/v1/instances/{instance_id}/bots:setDesiredState

Persists whether the selected bots should be running or stopped. The request returns after the desired state is durable. Connections are reconciled asynchronously and can be observed through WatchBotStatuses.

Authorization

AuthorizationBearer <token>

Preferred API authentication. Use a JWT with the api audience.

In: header

Path Parameters

instance_id*string
Formatuuid

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Changes persistent desired state for a batch of configured bots.

botIds*array<string>
Formatuuid
desiredState*soulfire.v1.BotDesiredState

Persistent operator intent for a bot.

Value in

  • "BOT_DESIRED_STATE_UNSPECIFIED"
  • "BOT_DESIRED_STATE_STOPPED"
  • "BOT_DESIRED_STATE_RUNNING"

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/bots:setDesiredState" \  -H "Content-Type: application/json" \  -d '{    "botIds": [      "string"    ],    "desiredState": "BOT_DESIRED_STATE_UNSPECIFIED"  }'
{  "bots": [    {      "profileId": "faebe71b-2bf8-4bdb-9b67-258e4d6aa00a",      "desiredState": "BOT_DESIRED_STATE_UNSPECIFIED",      "runtimeState": "BOT_RUNTIME_STATE_UNSPECIFIED",      "lastError": "string",      "updatedAt": "2019-08-24T14:15:22Z"    }  ]}

How is this page?