Skip to content

OpenAPI

Open API Documentation

This API allows interaction with the Frame device.

Base URL

https://api.galaxyguide.cn/openapi

Authentication

All endpoints require authentication using a Bearer Token. The token is the apikey of the device. The apikey can be found on the Frame's settings page.

Header:

Authorization: Bearer <apikey>

Endpoints

1. Get Device Information

Retrieves the current status and information of the device.

  • URL: /device
  • Method: POST
  • Content-Type: application/json
  • Request Body:
    • Empty JSON object {} or ignored.
  • Success Response:
    • Code: 200 OK
    • Content:
      {
          "firmware": "B100V050610",
          "nickname": "KoKonna",
          "lastHeartbeat": "2025-06-16T06:56:25.782Z",
          "isCharging": false,
          "batteryLevel": 100,
          "sdUsedSize": 0,
          "switchType": "random",
          "switchMinute": 60,
          "imageId": 423,
          "coverId": null,
          "timezone": "America/Adak",
          "point": 30,
          "screenWidth": 800,
          "screenHeight": 480,
          "screenRotate": 270,
          "online": false
      }

2. Upload Image

Uploads an image to the device.

  • URL: /upload
  • Method: POST
  • Content-Type: application/json
  • Request Body:
    • base64 (string, required): The base64 encoded string of the image.
    • name (string, optional): The name of the image file.
    {
        "base64": "/9j/4AAQSkZJRgABAQEAAAAAAAD...",
        "name": "photo.jpg"
    }
  • Success Response:
    • Code: 200 OK
    • Content:
      {
          "id": 789,
          "counter": 10
      }
    • id: The ID of the uploaded image.
    • counter: The updated frame image counter.

Error Handling

  • 404 Not Found: If the method specified in the URL is incorrect.
    {
        "message": "can not find method <method_name>"
    }
  • 500 Internal Server Error: If the robot (device) is not found or an internal error occurs.
    {
        "message": "can not find robot <apikey>"
    }
    OR
    {
        "message": "<error_message>"
    }
Back to top