Skip to main content
GET
/
open-api-playback
Playback Historical Data
curl --request GET \
  --url https://bounpkufhwhptqbktpfl.supabase.co/functions/v1/open-api-playback
{
  "code": 123,
  "record": "<string>",
  "cached": true,
  "timestamp": 123
}
Get historical GPS tracking data for a device within a specified time period. Returns playback data in semicolon-separated format matching Chinese API.

Request

access_token
string
required
API access token from authorization endpoint
imei
string
required
Single IMEI to get playback data for
begintime
long
required
Begin time (Unix timestamp in seconds)
endtime
long
required
End time (Unix timestamp in seconds)

Request Example

curl "https://bounpkufhwhptqbktpfl.supabase.co/functions/v1/open-api-playback?access_token=example_access_token_12345&imei=123456789012345&begintime=1609459200&endtime=1612051200"

Response

code
number
Response code (0 = success)
record
string
Semicolon-separated playback data. Each point format: “longitude,latitude,gpstime,speed,course”
cached
boolean
Indicates if response was from cache
timestamp
number
Unix timestamp

Success Response

{
  "code": 0,
  "record": "0.0,0.0,1609459200,0,0;0.0,0.0,1609459260,0,0;0.0,0.0,1609459320,0,0",
  "cached": false,
  "timestamp": 1609459200
}

Record Format

Each point: "longitude,latitude,gpstime,speed,course" Multiple points: separated by semicolon ";"

Example Record Breakdown

Point 1: longitude=0.0, latitude=0.0, gpstime=1609459200, speed=0, course=0
Point 2: longitude=0.0, latitude=0.0, gpstime=1609459260, speed=0, course=0
Point 3: longitude=0.0, latitude=0.0, gpstime=1609459320, speed=0, course=0

Rate Limits

5 requests per minute per user. Minimum interval: 12 seconds between requests. Cache TTL: 5 minutes (historical data, rarely changes).

Error Codes

Query Parameters

access_token
string
required

API access token from authorization endpoint

imei
string
required

Single IMEI to get playback data for

begintime
integer<int64>
required

Begin time (Unix timestamp in seconds)

endtime
integer<int64>
required

End time (Unix timestamp in seconds)

Response

Success

code
integer

Response code (0 = success)

record
string

Semicolon-separated playback data

cached
boolean

Indicates if response was from cache

timestamp
integer<int64>

Unix timestamp