example-data.com
Menu
Browse docs and collections

Overview

attachments / #548

Activity #548

User #10 attached image/png (3314815 bytes)

3/27/2026, 9:02:35 AM

Component variants

Medium
Small

User #10 attached image/png (3314815 bytes) · 3/27/2026, 9:02:35 AM

Related

Request

curl example

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

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/attachments/548"
);
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/548"
);
const attachment = (await res.json()) as Attachment;

Python example

import requests

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

Response

{
  "id": 548,
  "userId": 10,
  "targetType": "recipe",
  "targetId": 114,
  "url": "https://picsum.photos/seed/attachment-548/600/600",
  "mimeType": "image/png",
  "sizeBytes": 3314815,
  "createdAt": "2026-03-27T09:02:35.431Z"
}