Docs / Yamcs HTTP API / Commanding / Edit Command Queue

Edit Command Queue

Edit a command queue:

PATCH /api/processors/:instance/:processor/cqueues/:name

Parameters

Name Type Description
state string The state of the queue. Either enabled, disabled or blocked.

The same parameters can also be specified in the request body. In case both query string parameters and body parameters are specified, they are merged with priority being given to query string parameters.

Example

Block a queue:

{
  "state" : "blocked"
}

The response contains the updated queue information:

Status: 200 OK
{
  "instance" : "simulator",
  "processorName" : "realtime",
  "name" : "default",
  "state" : "BLOCKED",
  "nbSentCommands" : 0,
  "nbRejectedCommands" : 0
}

Alternative Media Types

Protobuf

Use these HTTP headers:

Content-Type: application/protobuf
Accept: application/protobuf

Request is of type:

rest/rest.proto 
message EditCommandQueueRequest {
  optional string state = 1;
}

Response is of type:

commanding/commanding.proto 
message CommandQueueInfo {
  required string instance = 1;
  required string processorName = 2;
  required string name = 3;
  optional QueueState state = 4;
  required int32 nbSentCommands = 5;
  required int32 nbRejectedCommands = 6;
  optional int32 stateExpirationTimeS = 7;
  repeated CommandQueueEntry entry = 8;
}