Skip to main content
GET
/
open-api-list-vehicles
List Vehicles
curl --request GET \
  --url https://bounpkufhwhptqbktpfl.supabase.co/functions/v1/open-api-list-vehicles
{
  "code": 123,
  "record": [
    {
      "id": "<string>",
      "imei": "<string>",
      "name": "<string>",
      "plate_number": "<string>",
      "type": "<string>",
      "brand": "<string>",
      "model": "<string>",
      "year": 123,
      "color": "<string>",
      "status": "<string>",
      "devicename": "<string>",
      "devicetype": "<string>",
      "simcard": "<string>",
      "iccid": "<string>",
      "image_name": "<string>",
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    }
  ],
  "cached": true,
  "timestamp": 123
}
Get a list of all vehicles (devices) associated with the authenticated user’s account. Returns complete vehicle information including IMEI, name, plate number, and all metadata.

Request

access_token
string
required
API access token from authorization endpoint

Request Example

curl "https://bounpkufhwhptqbktpfl.supabase.co/functions/v1/open-api-list-vehicles?access_token=example_access_token_12345"

Response

code
number
Response code (0 = success)
record
array
Array of vehicle objects
id
string
Vehicle UUID
imei
string
Device IMEI number
name
string
Vehicle name
plate_number
string
Vehicle plate number
type
string
Vehicle type (e.g., “Car”)
brand
string
Vehicle brand
model
string
Vehicle model
year
number
Vehicle year
color
string
Vehicle color
status
string
Vehicle status (e.g., “active”)
notes
string
Vehicle notes
fuel_type
string
Vehicle fuel type (e.g., “Gasoline”)
odometer
number
Vehicle odometer reading
devicename
string
Device name
devicetype
string
Device type
simcard
string
SIM card number
iccid
string
ICCID number
image_name
string
Vehicle icon/image filename
created_at
string
Creation timestamp (ISO 8601)
updated_at
string
Last update timestamp (ISO 8601)
cached
boolean
Indicates if response was from cache
timestamp
number
Unix timestamp

Success Response

{
  "code": 0,
  "record": [
    {
      "id": "example-uuid-1234-5678-9012-345678901234",
      "imei": "123456789012345",
      "name": "Example Vehicle",
      "plate_number": "ABC-123",
      "type": "Car",
      "brand": "ExampleBrand",
      "model": "ExampleModel",
      "year": 2020,
      "color": "Blue",
      "status": "active",
      "notes": "Example vehicle",
      "fuel_type": "Gasoline",
      "odometer": 50000,
      "devicename": "Example Device",
      "devicetype": "GPS Tracker",
      "simcard": "1234567890",
      "iccid": "ICCID123",
      "image_name": "v1.png",
      "created_at": "2024-01-01T00:00:00Z",
      "updated_at": "2024-01-01T00:00:00Z"
    }
  ],
  "cached": false,
  "timestamp": 1609459200
}

Response Headers

  • X-Cached: true/false (indicates if response was from cache)
  • X-RateLimit-Limit: 10 (max requests per minute)
  • X-RateLimit-Remaining: Remaining requests
  • X-RateLimit-Reset: Reset timestamp

Rate Limits

10 requests per minute per user. Minimum interval: 6 seconds between requests. Cache TTL: 60 seconds.

Error Codes

Query Parameters

access_token
string
required

API access token from authorization endpoint

Response

Success

code
integer

Response code (0 = success)

record
object[]
cached
boolean

Indicates if response was from cache

timestamp
integer<int64>

Unix timestamp