REST /api/v1/file-downloads 4 endpoints
POST /api/v1/file-downloads/api/v1/file-downloads/from-url

Trigger client download from a signed URL

Public

Request Example

{
  "url": "https://storage.example.no/exports/org_482/rpt_20250101_region07_pdf.pdf?token=tok_abc",
  "filename": "bufdir_export_rogaland_2025.pdf",
  "mime_type": "application/pdf"
}

Response Example

{
  "initiated": true,
  "filename": "bufdir_export_rogaland_2025.pdf",
  "mime_type": "application/pdf"
}
POST /api/v1/file-downloads/api/v1/file-downloads/from-bytes

Trigger client download from raw bytes (base64)

Public

Request Example

{
  "bytes_base64": "JVBERi0xLjQKJ...",
  "filename": "bufdir_export_rogaland_2025.pdf",
  "mime_type": "application/pdf"
}

Response Example

{
  "initiated": true,
  "filename": "bufdir_export_rogaland_2025.pdf",
  "size_bytes": 204800,
  "mime_type": "application/pdf"
}
POST /api/v1/file-downloads/api/v1/file-downloads/share

Share a file (native share sheet on mobile)

Public

Request Example

{
  "file_path": "/tmp/bufdir_export_rogaland_2025.pdf"
}

Response Example

{
  "shared": true,
  "file_path": "/tmp/bufdir_export_rogaland_2025.pdf"
}
DELETE /api/v1/file-downloads/api/v1/file-downloads/temp

Delete a temporary local file after download/share

Public

Request Example

{
  "file_path": "/tmp/bufdir_export_rogaland_2025.pdf"
}

Response Example

{
  "deleted": true,
  "file_path": "/tmp/bufdir_export_rogaland_2025.pdf",
  "deleted_at": "2026-03-26T10:35:00Z"
}

Additional Metadata

{
  "contract_summary": {
    "total_contracts": 410,
    "total_endpoints": 2416,
    "api_styles_used": [
      "rest"
    ]
  },
  "generated_at": "2026-03-26T06:55:53.316Z"
}