> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dashlink.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Update a QR code

> Edit an existing QRCode document and optionally update its attached image. All parameters should be sent as form-data.



## OpenAPI

````yaml /api-reference/openapi.json post /api/v1/qrcode/edit_qr_code
openapi: 3.1.0
info:
  title: Dashlink API
  version: 1.0.0
  description: >
    The Dashlink API lets you do programmatically what your team does in the
    Dashlink

    dashboard: create and manage Shortlinks, generate QR codes, organise work
    into

    campaigns, connect your own domains, and read click analytics.


    **Base URL:** `https://api.dashlink.ai`


    **Authentication:** every request needs an API key in the `X-API-Key`
    header.

    Create one in the dashboard under Settings → API Keys.


    ```bash

    curl https://api.dashlink.ai/api/v1/shortlinks/get_shortlinks \
      -H "X-API-Key: dlk_live_..."
    ```


    **Responses** are always wrapped. Success returns `{"data": ...}` and
    failure

    returns `{"error": {"message": ..., "status_code": ..., "code": ...}}`, so
    one

    code path handles every endpoint.


    **Rate limits** depend on your plan, from 500 requests per minute on Free to

    uncapped on Enterprise. Every response carries `X-RateLimit-Remaining`.
  contact:
    name: Dashlink Support
    email: support@dashlink.ai
  license:
    name: Proprietary
    url: https://dashlink.ai/terms
servers:
  - url: https://api.dashlink.ai
    description: Production
security:
  - apiKey: []
tags:
  - name: Links
    description: >-
      Create, read, update and delete Shortlinks. Deletion is bulk-only: to
      delete a single link, pass a one-element array.
  - name: App Dynamic Links
    description: >-
      Links that route to an iOS or Android app when it is installed and fall
      back to the web when it is not. App dynamic links are Shortlink records,
      so an API key granted the `shortlinks` module covers them.
  - name: QR Codes
    description: >-
      Generate and style QR codes. Every QR code is backed by a Shortlink, so
      scans are tracked the same way clicks are.
  - name: Campaigns
    description: >-
      Group links into campaigns and channels so their performance can be
      compared as a unit.
  - name: Analytics
    description: >-
      Click and scan analytics at three scopes: the whole organization, a single
      link, or a campaign. All analytics endpoints are read-only and are subject
      to your plan's retention window.
  - name: Branded Links
    description: >-
      Connect your own domain so Shortlinks carry your brand instead of the
      default Dashlink domain. Covers custom domains you own and platform
      subdomains Dashlink hosts for you.
  - name: Tags
    description: Organise links and QR codes with tags, and filter lists by them.
  - name: UTM Templates
    description: >-
      Reusable sets of UTM parameters, so campaign tagging stays consistent
      across everyone creating links.
  - name: Dynamic Link Templates
    description: >-
      Reusable app setup for Dynamic Links: domain, desktop fallback, and iOS
      and Android behaviour. Applying a template fills the create form. It does
      not change links already created.
  - name: Users & Organization
    description: Read your organization's profile and its members.
  - name: Account Limits
    description: >-
      What your plan allows and how much of it you have used. Check these before
      a bulk create so you fail early rather than halfway through.
paths:
  /api/v1/qrcode/edit_qr_code:
    post:
      tags:
        - QR Codes
      summary: Update a QR code
      description: >-
        Edit an existing QRCode document and optionally update its attached
        image. All parameters should be sent as form-data.
      operationId: qrcode_edit_qr_code
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                background_color:
                  type: string
                  description: >-
                    QR background fill color, as a hex string. Defaults to
                    `#FFFFFF`.
                background_color_secondary:
                  type: string
                  description: >-
                    Second gradient stop color when `background_style` is
                    `Gradient`, as hex. Defaults to `#FFFFFF`.
                background_style:
                  type: string
                  description: 'Background fill: `Solid` or `Gradient`. Defaults to `Solid`.'
                center_logo:
                  type: string
                  description: >-
                    Center-logo style for the code, by name. Determines whether
                    a center image or text is shown.
                center_logo_size_rem:
                  type: string
                  description: >-
                    Center-logo size in rem. Clamped to 0.9–5.0; defaults to
                    3.0.
                center_logo_text:
                  type: string
                  description: >-
                    Text rendered as the center logo when the center style is
                    the custom-text type.
                code_corner_style:
                  type: string
                  description: >-
                    Finder/corner-eye style: `square`, `rounded`, `circle`,
                    `circle-rounded`, `circle-diamond`, `circle-star` or
                    `rounded-circle`. Defaults to `square`.
                code_pattern:
                  type: string
                  description: >-
                    Module (dot) pattern: `square`, `rounded`, `dot`,
                    `dot-small`, `diamond`, `star`, `fluid`, `fluid-line`,
                    `stripe`, `stripe-row`, `stripe-column` or `tile`. Defaults
                    to `square`.
                code_shape:
                  type: string
                  description: >-
                    Overall code outline: `square` or `circle`. Defaults to
                    `square`.
                corner_color:
                  type: string
                  description: >-
                    Color of the corner/finder eyes, as hex. Defaults to
                    `#000000`.
                frame:
                  type: string
                  description: >-
                    Decorative frame around the code, by name (for example `Flat
                    border without text`, `Price Tag`, `Ticket Stub`). Optional.
                frame_color:
                  type: string
                  description: Frame color, as hex. Optional.
                frame_palette:
                  type: string
                  description: >-
                    Rich-frame color palette as a JSON object with `primary` and
                    `secondary` keys. Optional.
                frame_text:
                  type: string
                  description: Primary caption / call-to-action text shown in the frame.
                frame_text_color:
                  type: string
                  description: Frame caption text color, as hex. Defaults to `#ffffff`.
                frame_text_font_size_rem:
                  type: string
                  description: >-
                    Frame caption font size in rem. Clamped to 1.0–1.9; defaults
                    to 1.3.
                frame_text_secondary:
                  type: string
                  description: Secondary (second-line) frame caption text.
                is_dashlink_branding:
                  type: string
                  description: >-
                    Whether to show Dashlink branding on the code. Send `true`
                    or `false`.
                is_transparent_background:
                  type: string
                  description: >-
                    Whether the background is transparent. Send `1` or `0`.
                    Defaults to `0`.
                name:
                  type: string
                  description: The resource identifier.
                pattern_color:
                  type: string
                  description: Color of the QR data modules, as hex. Defaults to `#000000`.
                title:
                  type: string
                  description: Human-readable name shown in the dashboard.
                center_logo_image:
                  type: string
                  format: binary
                  description: >-
                    Uploaded center-logo image (jpeg/jpg/png, up to 500 KB,
                    100×100 to 1000×1000 px).
                file_path:
                  type: string
                  format: binary
                  description: >-
                    The uploaded file itself (binary), sent as a multipart file
                    part — not a server path.
                jpeg_file_path:
                  type: string
                  format: binary
                  description: Uploaded JPEG export of the code (up to 5 MB).
                svg_file_path:
                  type: string
                  format: binary
                  description: Uploaded SVG export of the code (up to 5 MB).
              required:
                - name
      responses:
        '200':
          description: Success.
          headers:
            X-RateLimit-Limit:
              schema:
                type: integer
              description: Requests allowed per minute on your plan. `-1` means uncapped.
            X-RateLimit-Remaining:
              schema:
                type: integer
              description: Requests left in the current window.
            X-RateLimit-Reset:
              schema:
                type: integer
              description: Seconds until the window resets.
            X-RateLimit-Plan:
              schema:
                type: string
              description: The plan the limit was derived from.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    description: The endpoint's payload.
                    additionalProperties: true
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '409':
          $ref: '#/components/responses/Conflict'
        '429':
          $ref: '#/components/responses/RateLimited'
        '500':
          $ref: '#/components/responses/ServerError'
components:
  responses:
    BadRequest:
      description: A parameter is missing, malformed, or outside its allowed range.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error:
              message: >-
                Invalid sort_by option. Choose from name, most_recent,
                last_modified
              status_code: 400
              code: INVALID_PARAMETER
              details:
                parameter: sort_by
                value: most_clicked
                valid_options:
                  - name
                  - most_recent
                  - last_modified
    Unauthorized:
      description: The API key is missing, malformed, expired, or revoked.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error:
              message: Authentication required. Please provide valid credentials.
              status_code: 401
              code: AUTHENTICATION_REQUIRED
    Forbidden:
      description: >-
        The key is valid but is not permitted to do this. Usually a restricted
        key without the right module grant, or a read-only key attempting a
        write.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error:
              message: You do not have permission to perform this action.
              status_code: 403
              code: PERMISSION_DENIED
    NotFound:
      description: >-
        No such resource. Also returned for a resource that belongs to another
        organization, so the response cannot be used to discover which ids
        exist.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error:
              message: Shortlink not found.
              status_code: 404
              code: NOT_FOUND
    Conflict:
      description: >-
        The resource already exists. Most often a back-half already taken on
        that domain.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error:
              message: This back-half is already in use on that domain.
              status_code: 409
              code: DUPLICATE_ENTRY
    RateLimited:
      description: >-
        Too many requests this minute. `Retry-After` says how many seconds to
        wait; `X-RateLimit-Reset` says when the window rolls over.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error:
              message: Rate limit exceeded. Please retry in 43 seconds.
              status_code: 429
              code: RATE_LIMIT_EXCEEDED
    ServerError:
      description: Something failed on our side. Safe to retry with backoff.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error:
              message: An unexpected error occurred. Please try again.
              status_code: 500
              code: INTERNAL_SERVER_ERROR
  schemas:
    Error:
      type: object
      description: The single error shape returned by every endpoint.
      properties:
        error:
          type: object
          required:
            - message
            - status_code
          properties:
            message:
              type: string
              description: A human-readable description of what went wrong.
            status_code:
              type: integer
              description: Matches the HTTP status code of the response.
            code:
              type: string
              description: >-
                A stable machine-readable code such as `NOT_FOUND` or
                `RATE_LIMIT_EXCEEDED`. Branch on this rather than on the message
                text.
            details:
              type: object
              description: >-
                Which parameter was at fault, when the error is about a
                parameter.
              additionalProperties: true
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Your API key, for example `dlk_live_...`. Create one in the dashboard
        under Settings → API Keys. Keys are shown once at creation and stored
        only as a hash, so they cannot be recovered.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.