Variables
Create variables
Creates variables in your workspace.
The shape of data depends on type: string and number take an example and an optional fallback, hyperlink takes text and url, list takes an array of strings, and map takes an object of string keys to string values.
Either every variable is created or none is.
post/variables
Request
- Base URL: https://api.dittowords.com/v2
- URL: https://api.dittowords.com/v2/variables
- Auth: API key in header Authorization
Request body
Example request
{
"variables": [
{
"name": "user_name",
"type": "string",
"data": {
"example": "Jane Doe",
"fallback": "there"
}
},
{
"name": "help_link",
"type": "hyperlink",
"data": {
"text": "Learn more",
"url": "https://dittowords.com"
}
}
]
}Response
Returns the names of the created variables
Example response
{
"names": [
"user_name",
"help_link"
]
}Changes
No recorded changes to this operation across all 1 revision of this API.