agents
agents
Page 3 of 3.
Overview
Request
curl example
curl -sS \ "https://example-data.com/api/v1/agents?limit=25"
JavaScript example
const res = await fetch(
"https://example-data.com/api/v1/agents?limit=25"
);
const { data, meta } = await res.json(); TypeScript example
// Download once: mkdir -p types && curl -o types/agents.d.ts https://example-data.com/types/agents.d.ts
import type { Agent, ListEnvelope } from "./types/agents";
const res = await fetch(
"https://example-data.com/api/v1/agents?limit=25"
);
const { data, meta } = (await res.json()) as ListEnvelope<Agent>; Python example
import requests
res = requests.get(
"https://example-data.com/api/v1/agents",
params={"limit": 25},
)
data = res.json() Response
{
"data": [
{
"id": 49,
"userId": 207,
"brokerage": "Redfin",
"licenseNumber": "8YZT4PQQB3",
"specialty": "residential",
"yearsExperience": 6,
"rating": 4.2,
"ratingCount": 111,
"createdAt": "2021-10-13T21:48:27.199Z"
},
{
"id": 50,
"userId": 235,
"brokerage": "Keller Williams",
"licenseNumber": "L5UZJ6RCMY",
"specialty": "land",
"yearsExperience": 18,
"rating": 4.5,
"ratingCount": 23,
"createdAt": "2020-02-18T02:50:44.526Z"
}
],
"meta": {
"page": 3,
"limit": 24,
"total": 50,
"totalPages": 3
},
"links": {
"self": "/api/v1/agents?page=3&limit=24",
"first": "/api/v1/agents?page=1&limit=24",
"last": "/api/v1/agents?page=3&limit=24",
"next": null,
"prev": "/api/v1/agents?page=2&limit=24"
}
}