Skip to main content

Update voucher template

Method PUT

https://my.easyweek.io/api/public/v2/voucher-templates/{template_uuid}

Description: This endpoint updates a voucher template. It uses PATCH semantics — only the fields present in the body are changed; omitted fields are kept.

caution

Once any voucher has been issued from the template, its structural/financial fields (cost, value, is_single_charge, validity, branch_uuids, service_uuids, good_uuids) are frozen — sending any of them returns 409. Presentation fields (title, description, colors, enabled, online, website/marketplace visibility, sales_limit) can still be updated.

Example Request

curl -i -X PUT \
https://my.easyweek.io/api/public/v2/voucher-templates/{template_uuid} \
-H 'Authorization: Bearer <YOUR_SECRET>' \
-H 'Workspace: <YOUR_WORKSPACE>'

Request body

{
"title": "Gift 100 (updated)",
"description": "New year promo",
"is_enabled": false
}

Path Parameters

  • template_uuid (string, required): The unique identifier of the voucher template to update.

Body Parameters

Any subset of the Create voucher template fields. Structural fields are rejected with 409 once vouchers have been issued.

Example Response

{
"uuid": "d3f1c2b4-6a7e-4b1c-9d0e-1f2a3b4c5d6e",
"title": "Gift 100 (updated)",
"description": "New year promo",
"notes": null,
"primary_color": "blue",
"is_single_charge": false,
"cost": 9000,
"value": 10000,
"is_connected_all_branches": true,
"all_branches_count": 3,
"branches_count": 3,
"is_connected_all_services": true,
"all_services_count": 12,
"services_count": 12,
"is_connected_all_goods": false,
"all_goods_count": 5,
"goods_count": 0,
"vouchers_count": 0,
"activated_vouchers_count": 0,
"validity": 12,
"activate_at": null,
"forces_activation": false,
"activate_after": 0,
"is_enabled": false,
"has_limit_of_sales": true,
"sales_limit": 100,
"is_online": true,
"is_shown_on_website": true,
"is_shown_in_marketplace": true,
"created_at": "2026-07-16T09:00:00+0000"
}