cURL
curl --request POST \ --url https://control-plane.kubiya.ai/api/v1/templates/extract-variables \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "template": "User {{user}} accessing {{.secret.database}} on {{.env.HOST}}" } '
{ "env_vars": [ "HOST" ], "secrets": [ "database" ], "simple_vars": [ "user" ], "variables": [ { "display_name": "user", "end": 13, "name": "user", "raw": "{{user}}", "start": 5, "type": "simple" } ] }
Extract all variables from a template without validation or compilation.
Useful for:
Enter your Kubiya API token (format: Bearer )
Request schema for extracting variables from a template.
Template string to analyze
1
Successful Response
Response schema for variable extraction endpoint.
All variables found in template
Show child attributes
Secret names required
Environment variable names required
Simple variable names required
Was this page helpful?