Skip to content

Download original file

GET
/api/v1/file-imports/{fileImportId}/file
curl --request GET \
--url http://localhost:8080/api/v1/file-imports/fileImport-0198a2b1-8f3e-7c2d-9a4b-1f2e3d4c5b6a/file \
--header 'Authorization: Bearer <token>'

Returns the file exactly as it was uploaded

fileImportId
required
string

The prefixed file import identifier, fileImport- included, as listed in /api/v1/file-imports.

The original .fit, .tcx or .gpx file.

Media typeapplication/octet-stream
string format: binary
Content-Disposition
string

The Authorization header was missing, malformed, or did not match the configured key.

Media typeapplication/json

Every error uses this shape.

object
error
required

A stable, machine readable code.

string
Allowed values: invalid_token insufficient_scope missing_file unsupported_media_type unsupported_file_type file_too_large import_mode_not_files file_not_available not_found method_not_allowed bad_request internal_error
message
required
string

Examples

ExampleinvalidToken
{
"error": "invalid_token",
"message": "A valid token is required. Send it in the Authorization header as a Bearer token."
}
WWW-Authenticate
string

The file import does not exist, or it has no stored file.

Media typeapplication/json

Every error uses this shape.

object
error
required

A stable, machine readable code.

string
Allowed values: invalid_token insufficient_scope missing_file unsupported_media_type unsupported_file_type file_too_large import_mode_not_files file_not_available not_found method_not_allowed bad_request internal_error
message
required
string

Examples

No such file import

{
"error": "not_found",
"message": "File import \"fileImport-1\" is no longer available"
}