example-data.com
Menu
Browse docs and collections

Overview

attachments / #468

Activity #468

User #90 attached image/png (46898331 bytes)

3/23/2026, 11:14:55 PM

Component variants

Medium
Small

User #90 attached image/png (46898331 bytes) · 3/23/2026, 11:14:55 PM

Related

Request

curl example

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

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/attachments/468"
);
const attachment = await res.json();

TypeScript example

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

const res = await fetch(
  "https://example-data.com/api/v1/attachments/468"
);
const attachment = (await res.json()) as Attachment;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/attachments/468"
)
attachment = res.json()

Response

{
  "id": 468,
  "userId": 90,
  "targetType": "product",
  "targetId": 165,
  "url": "https://picsum.photos/seed/attachment-468/600/400",
  "mimeType": "image/png",
  "sizeBytes": 46898331,
  "createdAt": "2026-03-23T23:14:55.951Z"
}