example-data.com
Menu
Browse docs and collections

Overview

attachments / #86

Activity #86

User #195 attached application/pdf (16640616 bytes)

8/14/2025, 10:52:35 AM

Component variants

Medium
Small

User #195 attached application/pdf (16640616 bytes) · 8/14/2025, 10:52:35 AM

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 86,
  "userId": 195,
  "targetType": "recipe",
  "targetId": 51,
  "url": "https://example.com/files/attachment-86.pdf",
  "mimeType": "application/pdf",
  "sizeBytes": 16640616,
  "createdAt": "2025-08-14T10:52:35.640Z"
}