example-data.com
Menu
Browse docs and collections

Overview

attachments / #195

Activity #195

User #193 attached image/jpeg (3293985 bytes)

3/16/2026, 4:20:01 PM

Component variants

Medium
Small

User #193 attached image/jpeg (3293985 bytes) · 3/16/2026, 4:20:01 PM

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 195,
  "userId": 193,
  "targetType": "comment",
  "targetId": 204,
  "url": "https://picsum.photos/seed/attachment-195/800/400",
  "mimeType": "image/jpeg",
  "sizeBytes": 3293985,
  "createdAt": "2026-03-16T16:20:01.239Z"
}