On this page

    1. Home
    2. API
    3. API Reference
    4. Device
    5. Device Share Code QR

    Device Share Code QR

    This endpoint generates a PNG image containing a QR code for a given device share code. This is useful for allowing users to scan and add devices to their network using mobile apps.


    GET /device/share-code/{code}/qr.png

    Retrieve the QR code image for a specific share code.

    Request

    GET /device/share-code/{code}/qr.png

    Headers:

    {
      "Host": "api.bringyour.com",
      "Authorization": "Bearer <YOUR_JWT_TOKEN>",
      "Accept": "image/png"
    }

    Parameters:

    NameInTypeRequiredDescription
    codepathstringYesThe unique share code generated via the create-share-code endpoint.

    Response

    200 Success

    Status: 200 OK Content-Type: image/png

    A successful response returns the raw binary data of the QR code image in PNG format.

    Example

    HTTP Request

    GET /device/share-code/SHARE-1234-5678/qr.png HTTP/1.1
    Host: api.bringyour.com
    Authorization: Bearer YOUR_JWT_TOKEN
    Accept: image/png

    Successful HTTP Response

    HTTP/1.1 200 OK
    Content-Type: image/png
     
    [Binary Image Data]


    Powered by Sudoc v2.5.0
    Hide table of contents