qrtap_create_code
Creates a managed QR code that encodes a stable short URL while allowing the destination to be edited later, so printed codes never need replacement.
Instructions
Create ONE managed QR code on QRTap. Returns the code object: id, short_url (the stable link the QR actually encodes — printing this once is safe because it never changes), png_url/svg_url for the rendered artifact, plus the label/group/external_ref you set. The destination behind the code is editable forever via qrtap_change_destination, so the printed sticker never has to be reissued. For more than a handful of codes at once use qrtap_create_codes_bulk instead — it is one request rather than N.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | Destination URL the code should redirect to (http/https, max 2048 chars). | |
| group | No | Analytics bucket for this code, one of: partner | equipment | event_menu | bag_insert | training. Codes sharing a group can be totalled in one call with qrtap_group_stats, so set it whenever a code belongs to a batch (a branch, a partner, an event). | |
| title | No | Human-readable label shown in the owner's cabinet (max 160 chars). Not visible to the person scanning. Defaults to 'Код'. | |
| external_ref | No | Your own identifier for this code (branch code, SKU, partner id, table number), max 200 chars. Two things depend on it: creation is idempotent by external_ref, so re-running the same call returns the existing code instead of minting a duplicate; and qrtap_list_codes can look a code up by it later. Always set it for batches — it is what makes a retry safe. | |
| design_template_id | No | Optional branded design template id (UUID) from qrtap_list_design_templates. Applies the organization's colour and centre logo to the rendered QR. |