Skip to main content

Endpoint

GET /v1/memory/:id/download
Stream a file directly with the correct Content-Type and Content-Disposition headers. Use this instead of GET /v1/memory/:id when you need the raw binary file rather than a base64-encoded JSON response.

Path Parameters

ParamDescription
idMemory UUID

Response Headers

HeaderDescription
Content-TypeOriginal MIME type (e.g. application/pdf) or application/octet-stream
Content-Dispositionattachment; filename="{name}{ext}"
Content-LengthFile size in bytes

Example

# Download to file
curl -o report.pdf "$API/v1/memory/$ID/download" \
  -H "Authorization: Bearer $API_KEY"

# Stream to stdout
curl "$API/v1/memory/$ID/download" \
  -H "Authorization: Bearer $API_KEY" > video.mp4
Use this endpoint for binary files. For text memories, GET /v1/memory/:id returns the content directly in JSON.

Credit Cost

This operation costs 1 credit (memory.read).

Errors

StatusReason
404Memory not found
502Failed to read from Shelby network