Skip to main content
PUT
Change a QR code: its design, its logo, its content, its PDF, or the settings of its link. It works with QR codes created by Create QR Code and with the QR of any link. PUT and PATCH behave the same.

How it works

Send url_id and only what changes. Everything you leave out keeps its value, also inside content and design: {"design": {"frame_layout": "balloon"}} changes the frame and keeps colors, pattern and eyes.
  • Design and logo: the keys you send go on top of the current design. Without logo the current logo stays. A qr_template_id restarts from that template.
  • Static types: the content fields you send replace those fields only.
  • PDF: a new pdf_data replaces the file (and pdf_name names the new one). The old file is deleted.
  • Link settings: url, domain_id, custom_slug and the other link fields work as in Edit Link.
  • The type of a QR code cannot change, and a QR code never moves to another workspace.

Request body

On a Free plan an edit can keep a paid style the QR code already has (for example after a downgrade), but it cannot add a new one.

Response

The same as Create QR Code, with data.created set to false.

Errors

As in Create QR Code, plus 400 when only url_id is sent, 404 when the QR code is not in your organization, and 422 when type is not the current one.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Only url_id is required, plus at least one field to change. Omitted fields keep their value, also inside content and design. The type cannot change.

url_id
integer
required

ID of the QR code (data.id of the creation).

Example:

9012

type
enum<string>

Optional: when sent it must be the current type.

Available options:
link,
pdf,
text,
wifi,
vcard,
mecard,
location,
bitcoin,
email,
phone,
sms,
whatsapp
content
text · object

Fields of a static QR code, by type. Required on creation; on edit send only the fields to change.

Example:
url
string

link only: destination URL. Required on creation.

Maximum string length: 2048
Example:

"https://example.com/menu"

domain_id
integer

link and pdf: domain that hosts the short link. Required on creation.

Example:

1

pdf_data
string

pdf only: the PDF file, base64-encoded (a data:application/pdf;base64, prefix is accepted). 20 MB at most. Required on creation; on edit it replaces the file.

pdf_name
string

pdf only: file name used for the download, with pdf_data. Defaults to document.pdf.

Maximum string length: 200
Example:

"Menu.pdf"

design
object

Styles of the QR code, as in the QR designer. Send only what you want to change: the rest comes from qr_template_id, else from the QR being edited, else from the defaults. On a Free plan only the first two values of module_style, eye_frame_style and eye_ball_style, and none or box for frame_layout, can be saved.

Example:

Logo in the center of the code: none, the organization logo, or the image in logo_data. Omitted: the template's logo, else the QR's current one (edit), else none.

Available options:
none,
organization,
upload
logo_data
string

PNG, JPEG or SVG image, base64-encoded (a data URI is accepted), 2 MB at most. Sending it implies logo: "upload".

qr_template_id
integer

QR template of the organization used as the starting design and logo; design and logo override it. Paid plans only.

Example:

7

title
string

link and pdf: title in your lists. A PDF without one gets the file name. Static types get a title from their content.

Maximum string length: 256
notes
string

Private note.

Maximum string length: 300
custom_slug
string

link and pdf: branded slug instead of an auto-generated code.

Maximum string length: 64
folder_id
integer

link and pdf: folder of the link.

tag_ids
integer[]

link and pdf: tags of the link (same rules as the link endpoints).

param
object

link only: query parameters added to the destination URL (for example UTM tags).

redirect_type
enum<integer>

link and pdf: redirect status.

Available options:
301,
302
with_password
boolean

link and pdf: protects the link with url_password.

url_password
string

Password asked before the redirect (or the download).

Response

QR code updated

success
boolean
required
Example:

true

status_code
integer
required
Example:

200

data
object
required
message
string
Example:

""