Document Download

Download report files in various formats.

Endpoint

POST /files/download

Parameters

Parameter
Type
Required
Description

report_id

string[]

Yes

Report IDs to download (max: 10)

format

string

Yes

Output format: pdf, extract, embedding

options

object

No

Format-specific options

Format Options:

  • PDF: {"include_exhibits": true}

  • Extract: {"format": "json", "include_tables": true, "page_numbers": true}

  • Embedding: {"model": "ada-002", "chunk_size": 1000}

Example Request

bash

curl -X POST "https://api.orbitfin.ai/v1/files/download" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "report_id": ["rpt_9xk3m7nq"],
    "format": "extract",
    "options": {
      "format": "json",
      "include_tables": true
    }
  }'

Response

json

{
  "status": "success",
  "credits_used": 0.5,
  "data": {
    "download_urls": [
      {
        "report_id": "rpt_9xk3m7nq",
        "url": "https://download.orbitfin.ai/temp/...",
        "expires_at": "2024-12-08T10:30:00Z",
        "file_size": 234567,
        "format": "extract"
      }
    ]
  }
}

Last updated