Resolve Variables
Substitute Liquid {{variable}} placeholders in prompt content.
Request
curl -X POST "https://platform.chanl.ai/api/v1/prompts/{promptId}/resolve" \
-H "X-API-Key: chanl_key_..." \
-H "Content-Type: application/json" \
-d '{
"variables": {
"customer_name": "Alice",
"order_id": "ORD-123"
}
}'const { data } = await chanl.prompts.resolve(promptId, {
variables: { customer_name: 'Alice', order_id: 'ORD-123' },
});
console.log(data.content);