API Docs

    Developer resources and guides for integrating QR Cake.

    JSON REST APIDynamic QR CreationBearer Authorization

    Quick Start

    The QR Cake API lets QR Cake users manage their account QR Codes.

    Base URL
    https://api.qrcake.com/v1/product

    Authentication

    Create an API key in your dashboard and send it in the Authorization header.

    Authorization: Bearer <API Key>
    Content-Type: application/json

    Manage API keys in Dashboard API Keys.

    API Request Tester

    Test endpoints directly from this page. Enter your API key, select an endpoint, and inspect the live response.

    Interactive API Tester

    Run requests directly from your browser to the selected QR Cake API endpoint.

    GET
    Authorization: Bearer <API Key>
    Resolved URL
    https://api.qrcake.com/v1/product/user/product
    Run a request to see live status and response output here.

    Terminology

    Products

    QR Codes

    Users

    QR Cake accounts

    Request Bodies (POST/PUT)

    For POST and PUT requests, request bodies must be stringified. If you are sending JSON, pass a JSON string (for example JSON.stringify(payload)).

    const payload = { redirect: "https://example.com", metadata: {} };
    
    await fetch(url, {
      method: "POST",
      body: JSON.stringify(payload),
    });
    GET

    List QR Codes

    Lists the QR Codes accessible to the API key.

    Open in GitBook
    Path: /user/product
    URL: https://api.qrcake.com/v1/product/user/product
    Request Details
    Headers
    • Authorization: Bearer <API Key>
    • Accept: application/json
    Responses
    200 OK
    [
      {
        "accountId": "string",
        "productId": "string",
        "userId": "string",
        "redirect": "string",
        "state": "ACTIVE",
        "metadata": {},
        "createdAt": 0,
        "updatedAt": 0
      }
    ]
    401 Unauthorized
    {
      "message": {}
    }

    Products = QR Codes.

    GET

    Get a QR Code

    Fetches one QR Code.

    Open in GitBook
    Path: /product/{productId}
    URL: https://api.qrcake.com/v1/product/product/{productId}
    Request Details
    Path params
    • productId (string)
    Headers
    • Authorization: Bearer <API Key>
    • Accept: application/json
    Responses
    200 OK
    {
      "accountId": "string",
      "productId": "string",
      "userId": "string",
      "redirect": "string",
      "state": "ACTIVE",
      "metadata": {},
      "createdAt": 0,
      "updatedAt": 0
    }
    401 Unauthorized
    {
      "message": {}
    }
    POST

    Create a QR Code

    Creates a new QR Code product.

    Open in GitBook
    Path: /product
    URL: https://api.qrcake.com/v1/product/product
    Request Details
    Headers
    • Authorization: Bearer <API Key>
    • Content-Type: application/json
    • Accept: application/json
    Body template
    {
      "redirect": "https://example.com",
      "metadata": {},
      "state": "ACTIVE"
    }
    Responses
    200 OK
    {
      "accountId": "string",
      "productId": "string",
      "userId": "string",
      "redirect": "string",
      "state": "ACTIVE",
      "metadata": {},
      "createdAt": 0,
      "updatedAt": 0
    }
    401 Unauthorized
    {
      "message": {}
    }

    POST request body must be stringified (for example, JSON.stringify(payload)).

    PUT

    Update a QR Code

    Updates an existing QR Code (product).

    Open in GitBook
    Path: /product/{productId}
    URL: https://api.qrcake.com/v1/product/product/{productId}
    Request Details
    Path params
    • productId (string)
    Headers
    • Authorization: Bearer <API Key>
    • Content-Type: application/json
    • Accept: application/json
    Body template
    {
      "redirect": "https://example.com",
      "metadata": {},
      "state": "ACTIVE"
    }
    Responses
    200 OK
    {
      "accountId": "string",
      "productId": "string",
      "userId": "string",
      "redirect": "string",
      "state": "ACTIVE",
      "metadata": {},
      "expiresAt": 0,
      "createdAt": 0,
      "updatedAt": 0
    }
    401 Unauthorized
    {
      "message": {}
    }

    PUT request body must be stringified.

    DELETE

    Delete a QR Code

    Deletes a QR Code.

    Open in GitBook
    Path: /product/{productId}
    URL: https://api.qrcake.com/v1/product/product/{productId}
    Request Details
    Path params
    • productId (string)
    Headers
    • Authorization: Bearer <API Key>
    • Accept: application/json
    Responses
    200 OK
    {
      "productId": "string"
    }
    401 Unauthorized
    {
      "message": {}
    }
    GET

    Permissions

    Returns the permissions granted to the API key.

    Open in GitBook
    Path: /permission
    URL: https://api.qrcake.com/v1/product/permission
    Request Details
    Headers
    • Authorization: Bearer <API Key>
    • Accept: application/json
    Responses
    200 OK
    {
      "success": true,
      "result": {
        "analytics": true,
        "productLimit": 100,
        "tier": "subscriber",
        "productTotal": 3,
        "productActiveLimit": 100,
        "productActiveTotal": 3
      }
    }
    401 Unauthorized
    {
      "message": {}
    }

    Supported QR Types

    Use these metadata types when creating or updating QR products.

    redirect, link, image, video, file, pdf, audio, app, event, vCard

    Start with dynamic QR codes and changeable QR codes on our homepage.