Variables
List all available variables.
Request
GET http://printer/api/v3/variables
Response
[
{
"name": "My First Variable",
"value": "ABC"
},
{
"name": "My Second Variable",
"value": "X Y Z"
}
]
Get a variable.
Request
GET http://printer/api/v3/variables/{name}
Path Parameters
| Name | Type | Description |
|---|---|---|
| name | String | Variable name |
Response
{
"description": "Optional description",
"userEdit": true,
"value": "ABC"
}
Delete a variable.
Request
DELETE http://printer/api/v3/variables/{name}
Path Parameters
| Name | Type | Description |
|---|---|---|
| name | String | Variable name |
Response
None.
Create or replace a variable.
Request
PUT http://printer/api/v3/variables/{name}
Path Parameters
| Name | Type | Description |
|---|---|---|
| name | String | Variable name |
Headers
| Name | Type | Description |
|---|---|---|
| Content-Type | String | application/json |
Body
| Name | Type | Description |
|---|---|---|
| value | string | Variable value. |
| description | string | A description that is shown in the UI instead of the name. |
| userEdit | boolean | If the variable shall be changeable when an operator selects a label containing the variable. |
Response
None.