Skip to main content

Developers · Reference

File Inputs

Downloads of files held by application and deliverable inputs. 1 operation: parameters, request body and answers, with examples.

GET /api/v2/file_inputs/{id}

Download the file an input holds.

The raw bytes of a live application’s file answer or a live milestone’s deliverable file, as tahua_file_url names it. A file still being scanned, infected or disposed is 404.

  • Operation ID: downloadFileInput
  • Authentication: A Bearer token from a credential holding the read scope.
  • Also served at /funding_system/api/v2/file_inputs/{id}, the documented product’s alias path.
Example request
curl "https://your-org.backed.giving/api/v2/file_inputs/55121" \
  -H "Authorization: Bearer $BACKED_TOKEN"

Parameters

Parameters of GET /api/v2/file_inputs/{id}
NameInRequiredTypeDescription
idpathYesintegerThe id of the file input to download, as its tahua_file_url names it. Example: 55121.

200 response

The file’s bytes, with its own content type.

Headers: Content-Disposition, Content-Length, Cache-Control.

The body is the raw bytes (*/*), not JSON.

401 response

The token is missing, invalid, expired or revoked, of another Organisation, or API access is not Full. Ask for a new token.

Headers: WWW-Authenticate.

Example 401 response
{
  "error": "invalid_token",
  "error_description": "The access token is invalid or has expired"
}

403 response

The request was sent over plain HTTP and was not processed.

Example 403 response
{
  "error": "https_required"
}

404 response

An unknown host or path, or an id that is unknown, deleted or of another Organisation.

Example 404 response
{
  "error": "not_found"
}

429 response

A rate limit was exceeded: 120 requests a minute per credential, 30 token requests a minute per client_id.

Headers: Retry-After.

Example 429 response
{
  "error": "rate_limited",
  "error_description": "Too many requests"
}

500 response

An unexpected server error.

Example 500 response
{
  "error": "server_error"
}

503 response

The Organisation’s API access cannot be determined, or a dependency is unavailable. Retry after the given seconds.

Headers: Retry-After.

Example 503 response
{
  "error": "temporarily_unavailable"
}