Tasks
Org Global Value
Performs an operation on or creates a pair of key-value data that is accessible to all stubs.
Uses
- Use to store a value across all your templates
- Use to store temporary data that you need across stubs
Basic usage
Parameters
required string
key The key on which the operation will be executed. It needs to consist of a minimum of five parts seperated with :
.
string
operation The operation that will be executed on the key.
Options:
set:
Sets the key to the value of the
savevalue
parameter.get:
Returns the value of the key.
delete:
Deletes the key.
increment:
Increments the value of the key.
decrement:
Decrements the value of the key.
savevalue
The value the key is set to, if the operation is set
.
expiry_date
If set, this determines the date at which the key's value will expire.
number
expire_in If set, this determines the amount of time, in seconds, after which the key's value will expire.
Result
Properties
string
key The key on which the operation was executed.
value
The value of the key after the operation has been executed.
Examples
Set value with expiry date
Set a global org value with an expiry date.
Get value and save to stub data
Get a global org value. You will need to use a savedata task to save the value into the stub.data.
Save the value from the previous task