API DocumentationDiscord ServerParserReference

API Documentation

How to call the RetroSolver API, what to send, and what you get back.

Endpoint

POSThttps://retrosolver.top/bmp/gen

Authentication

Send your API key in the X-API-Key header.

X-API-Key: sk_your_api_key_here
Content-Type: application/json
Each accepted request consumes credit and holds one of your concurrent thread slots for its duration. When all your threads are busy, further requests wait briefly, then receive 429.

Request payload

The body is a JSON object containing the following fields. Please note that all required fields must be included — omitting any of them will cause the API to return an error 400: Malformed request body.
We recommend using the parser to format the payload. For further information on using the parser, feel free to check out my Discord Server.
When a valid ID is passed in the payload, all other required fields are ignored — only the optional fields that are explicitly provided will be applied. Each ID corresponds to exactly one device and app pair. The required fields from the payload are stored internally.
When a Valid ID passed you will get the same ID in the Response.

Example body

{
  "version": "4.x.x",
  "config": {
    "package": {
      "versionName": "xx",
      "versionCode": "x",
      "name": "com.xx"
    },
    "appProperties": {
      "singersHash": "07bcf24f1cac05625301ba3ac6c2d3c11ed1b413",
      "frameworkType": 0,
      "sdkUrl": "https://xxx.com"
    },
    "systemProperties": {
      "timeZone": {
        "offset": "60"
      },
      "localInfo": {
        "countryCode": "US",
        "language": "en"
      }
    },
    "parameters": {
      "events": {
        "hasTouch": false
      }
    }
  }
}

Response

Every response is a JSON object with an success boolean telling you whether the request succeeded.

On success — 200

{
  "success": true,
  "result": {
    "id": "2e8569ad4566b95bd1efaa937da704f80d336fd21a10e95475382ba4d478b9bc",
    "sensor": "6,a,p....$92,56,71$$$"
  }
}

On failure

FieldTypeDescription
successbooleanAlways false on failure.
errorstringHuman-readable reason for the failure.
{
  "success": false,
  "error": "insufficient credit"
}

Errors

The failure reason is also reflected in the HTTP status code:

StatusMeaning
401Missing API key.
402Insufficient credit.
429Thread limit reached — too many concurrent requests. Retry shortly.
400Malformed request body, Sdk Version not supported, Error While Generating the sensor or Error While Generating the sensor from cache.
500Internal error.
403API key expired.
409Id already in use, try again later.

Example

JavaScript (fetch)

const res = await fetch("https://retrosolver.top/bmp/gen", {
  method: "POST",
  headers: {
    "X-API-Key": "sk_your_api_key_here",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "version": "4.x.x",
    "config": {
      "package": {
        "versionName": "xx",
        "versionCode": "x",
        "name": "com.xx"
      },
      "appProperties": {
        "singersHash": "07bcf24f1cac05625301ba3ac6c2d3c11ed1b413",
        "frameworkType": 0,
        "sdkUrl": "https://xxx.com"
      },
      "systemProperties": {
        "timeZone": {
          "offset": "60"
        },
        "localInfo": {
          "countryCode": "US",
          "language": "en"
        }
      },
      "parameters": {
        "events": {
          "hasTouch": false
        }
      }
    }
  })
});
const data = await res.json();
if (!data.ok) console.error(data.error);