> For the complete documentation index, see [llms.txt](https://apidocs.zerionsoftware.com/doc/iformbuilder-v81/llms.txt)

# Get Media

> GET /profiles/{profile_id}/media
> 
> Streams a private media file referenced by a record's image/file field. The `url` is the stored value: `privates3://`, `privatecloudfiles://`, `OneDriveApi:`, `SharePointApi:`, `GoogleDriveApi:`, `DropboxApi:`, or a Box (`https://*.box.com/shared/static/...`) or Dropbox (`https://*.dropbox.com/...?raw=1`) link. Box and Dropbox links are fetched only from their own hosts, over HTTPS, with bounded retries and timeouts.



## Servers
- https://api.iformbuilder.com/exzact/api/v81/[servername]: https://api.iformbuilder.com/exzact/api/v81/[servername]


## Authentication methods
- Oauth2


## Parameters
### Headers

- **Authorization** (string)
  e.g. Bearer {access_token}


### Path parameters

- **profile_id** (string)
  id of the profile


### Query parameters

- **url** (string)
  URL of the private media file, as returned in a record's image/file field



## Responses
### 200
OK - the file's raw bytes with the stored `Content-Type`.

#### Body: */* (string(binary))
string(binary)
### 400
Bad Request - the `url` names a storage path with a dot segment (`.`/`..`), a `privatecloudfiles://` path with an empty target or a dot segment, `?`, `#` or control character, or a connector id (`OneDriveApi:`, `SharePointApi:`, `GoogleDriveApi:`, `DropboxApi:`) containing a dot segment, `?`, `#` or a control character.

#### Body: application/json (object)
- **error_message** (string)
  human-readable reason for the failure


### 401
Unauthorized - missing or invalid bearer token.

#### Body: application/json (object)
- **error_message** (string)
  human-readable reason for the failure


### 403
Forbidden - the caller cannot access `profile_id`, or a `privates3://` url names a bucket outside the server's private media buckets (`mediaAWSS3Info.privateMediaBucket` plus `oldPrivateMediaBucketList`), or a `privatecloudfiles://` url names a country, region and container outside the server's private Cloud Files locations (`mediaPrivateMainServerLocationInfo`, `mediaPrivateBackupServerLocationInfo` plus `oldPrivateCloudFilesLocationList`), or either names a server other than this one or one in `oldServerIdList`, or (for a caller without server scope) another profile.

#### Body: application/json (object)
- **error_message** (string)
  human-readable reason for the failure


### 404
Not Found - the object does not exist or is empty, or the `url` is not a recognised private media reference.

#### Body: application/json (object)
- **error_message** (string)
  human-readable reason for the failure


### 409
Conflict - the profile's cloud-drive connection must be reconnected (reconnect required).

#### Body: application/json (object)
- **error_message** (string)
  human-readable reason for the failure


### 502
Bad Gateway - storage failed for a reason other than a missing object (any other S3 or Cloud Files error), or a Box/Dropbox host failed, timed out, redirected outside the provider, or was still answering 202 after 3 attempts.

#### Body: application/json (object)
- **error_message** (string)
  human-readable reason for the failure



[Powered by Bump.sh](https://bump.sh)
