example-data.com
Menu
Browse docs and collections

Overview

attachments / #238

Activity #238

User #113 attached application/pdf (32825528 bytes)

1/28/2026, 3:28:23 AM

Component variants

Medium
Small

User #113 attached application/pdf (32825528 bytes) · 1/28/2026, 3:28:23 AM

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 238,
  "userId": 113,
  "targetType": "restaurant",
  "targetId": 34,
  "url": "https://example.com/files/attachment-238.pdf",
  "mimeType": "application/pdf",
  "sizeBytes": 32825528,
  "createdAt": "2026-01-28T03:28:23.549Z"
}