example-data.com
Menu
Browse docs and collections

crypto-holdings

crypto-holdings

Page 18 of 21.

Overview

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/crypto-holdings?limit=25"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/crypto-holdings?limit=25"
);
const { data, meta } = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/crypto-holdings.d.ts https://example-data.com/types/crypto-holdings.d.ts
import type { CryptoHolding, ListEnvelope } from "./types/crypto-holdings";

const res = await fetch(
  "https://example-data.com/api/v1/crypto-holdings?limit=25"
);
const { data, meta } = (await res.json()) as ListEnvelope<CryptoHolding>;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/crypto-holdings",
    params={"limit": 25},
)
data = res.json()

Response

{
  "data": [
    {
      "id": 409,
      "userId": 204,
      "cryptoId": 11,
      "quantity": 65.05513564,
      "costBasis": 1.57180422,
      "purchasedAt": "2024-08-16T04:36:44.636Z"
    },
    {
      "id": 410,
      "userId": 204,
      "cryptoId": 21,
      "quantity": 14.10447386,
      "costBasis": 30.64706931,
      "purchasedAt": "2024-12-10T22:40:57.832Z"
    },
    {
      "id": 411,
      "userId": 205,
      "cryptoId": 6,
      "quantity": 10.43586413,
      "costBasis": 0.62266136,
      "purchasedAt": "2025-11-23T03:10:10.469Z"
    }
  ],
  "meta": {
    "page": 18,
    "limit": 24,
    "total": 498,
    "totalPages": 21
  },
  "links": {
    "self": "/api/v1/crypto-holdings?page=18&limit=24",
    "first": "/api/v1/crypto-holdings?page=1&limit=24",
    "last": "/api/v1/crypto-holdings?page=21&limit=24",
    "next": "/api/v1/crypto-holdings?page=19&limit=24",
    "prev": "/api/v1/crypto-holdings?page=17&limit=24"
  }
}