Skip to main content
GET
/
v2
/
vehicles
List all vehicles
curl --request GET \
  --url https://api-sandbox.argyle.com/v2/vehicles \
  --header 'Authorization: Basic <encoded-value>'
import requests

url = "https://api-sandbox.argyle.com/v2/vehicles"

headers = {"Authorization": "Basic <encoded-value>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};

fetch('https://api-sandbox.argyle.com/v2/vehicles', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api-sandbox.argyle.com/v2/vehicles",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api-sandbox.argyle.com/v2/vehicles"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Basic <encoded-value>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api-sandbox.argyle.com/v2/vehicles")
.header("Authorization", "Basic <encoded-value>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api-sandbox.argyle.com/v2/vehicles")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'

response = http.request(request)
puts response.read_body
{
  "next": "https://api-sandbox.argyle.com/v2/vehicles?cursor=ZXhhbXBsZV9jdXJzb3I",
  "previous": null,
  "results": [
    {
      "id": "0176364c-c8a2-4d43-2a12-7b4146a829a9",
      "account": "0187c66e-e7e5-811c-b006-2232f00f426a",
      "identification": "JASJ1Y",
      "make": "Ford",
      "model": "Focus",
      "type": "car",
      "year": 2011,
      "vin": "W081C4YIZQYE55DSE",
      "employer": "GigAntic",
      "created_at": "2023-02-09T13:28:11.427Z",
      "updated_at": "2023-02-09T13:32:13.215Z",
      "metadata": {
        "source": "gig platform"
      }
    },
    {
      "id": "01763a69-5cbe-2edb-ade1-5591157c354d",
      "account": "0187c66e-e7e5-811c-b006-2232f00f426a",
      "identification": "AEWUQ7",
      "make": "Ford",
      "model": "Mondeo",
      "type": "car",
      "year": 1998,
      "vin": "QUICELDKTRQJ4S33C",
      "employer": "GigAndGo",
      "created_at": "2023-02-09T13:42:03.966Z",
      "updated_at": "2023-02-09T13:42:03.966Z",
      "metadata": {}
    }
  ]
}

Authorizations

Authorization
string
header
required

Username = api_key_id, Password = api_key_secret

Query Parameters

account
string<uuid>

Filter by account ID.

user
string<uuid>

Filter by user ID.

limit
integer

Number of vehicle objects returned per page. Default: 10. Maximum: 200.

cursor
string

The URL returned in next or previous used to retrieve another page of results.

Response

200 - application/json
next
string<uri> | null

URL for the next page of results, if available.

previous
string<uri> | null

URL for the previous page of results, if available.

results
object[]