This took me a while to figure out, so in case it helps someone… Please document this!
Assume you have a secret named my-secret-thing
. This would be referenced like this:
var theSecret = context.webtask.secrets['my-secret-thing'];
If the secret’s name complies with JS symbol names, e.g. my_other_secret
, you can reference like this:
var theOtherSecret = context.webtask.secrets.my_other_secret;