example-data.com
Menu
Browse docs and collections

Overview

addresses / #145

work

userId
Elva Roberts @elva.roberts48
label
work
recipient
Erika Fadel
street1
46648 Demond Underpass
street2
city
Scranton
region
Colorado
postalCode
49165
countryAlpha2
SA
isDefault
false
createdAt

Component variants

Related

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/addresses/145" \
  -H "Accept: application/json"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/addresses/145"
);
const address = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/addresses.d.ts https://example-data.com/types/addresses.d.ts
import type { Address } from "./types/addresses";

const res = await fetch(
  "https://example-data.com/api/v1/addresses/145"
);
const address = (await res.json()) as Address;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/addresses/145"
)
addresse = res.json()

Response

{
  "id": 145,
  "userId": 107,
  "label": "work",
  "recipient": "Erika Fadel",
  "street1": "46648 Demond Underpass",
  "street2": null,
  "city": "Scranton",
  "region": "Colorado",
  "postalCode": "49165",
  "countryAlpha2": "SA",
  "isDefault": false,
  "createdAt": "2025-02-15T20:20:44.345Z"
}