Update a control app's content

Update control app

PATCH https://app.singular.live/apiv2/controlapps/:appToken/control

Updates the data of a sub-composition in an overlay. Either subCompositionID or subCompositionName is required.

Path Parameters

NameTypeDescription

appToken*

String

The shared app token is a unique token for a single app instance. How to find the shared app token.

Request Body

NameTypeDescription

subCompositionId*

String

The sub-composition ID. Either the subCompositionID or the subCompositionName must be included in the request. Get them from the payload of the Get control app model request.

payload*

Object

A JSON object that contains control-level elements of the sub-composition.

controlnodeID*

String

The ID of a control node.

controlNodeContent*

FieldType

New control node content.

subCompositionName*

String

The name of the sub-composition. Either the subCompositionID or the subCompositionName must be included in the request. Get them from the payload of the Get control app model request.

{
    "success": true
}

Example request bodies by sub-composition name or ID

[
  {
    "subCompositionName": "<subCompositionName>",
    "payload": {
      "<controlnodeId>": "<controlnode content>",
      "<...>": "<...>"
    }
  }, {
    ... 
  }
]

Control node field types

<fieldType>ExampleDescription

<Text>

"John Doe"

A single line of text.

<Text Area>

"Title/nSubtitle"

Multiple lines of text.

<Number>

123.45

A number.

<Image>

"https://www.gstatic.com/webp/gallery3/1.png"

An image URL.

<Color>

"lightgray", "#33AAFF", "#33AAFF55", rbg(150, 150, 150)", rgba(255, 150, 150, 0.5)"

An HTML color name, a color HEX code, a color HEX code with alpha, a color rgb value, or a color rgba value.

<Checkbox>

true, false

A checkbox checked (true) or unchecked (false).

<Audio>

"https://domain.com/audio.mp3"

The URK of an audio file.

JSON Text>

"{"id": 1,"firstname": "John","lastname": "Doe"}"

A stringified JSON object.

<Time Control>

{"command": "play"}, {"command": "pause"}, {"command": "reset"}

Plays, pauses, or resets the timer.

<Button>

"execute"

Triggers a button click event.

Last updated