Page History
...
The fetch page GET/POST request requires the storage unit name and optionally the scope. Parameters startId (first record by default), batchSize (10 by default) and zone (local zone by default) are optional.
Code Block | ||||
---|---|---|---|---|
| ||||
POST access/fetchPage/<storage-unit-name>/<optional:scope>?startId=123456&batchSize=20 |
...
- Call fetch page without a startId. This will return the first batchSize records of the storage unit sorted by key and a reference to the startId for the next page.
- Make subsequent calls with the startId of the previous request.
- Finish when page response doesn't contain a next page startId.
Get File
Downloads a file attached to a file scope of a record key in a storage unit.
Request
The get file GET request requires the storage unit name, the record key, the file scope and the file name to download (See putFile for upload info).
Code Block | ||||
---|---|---|---|---|
| ||||
GET access/getFile/<storage-unit>/<record-key>/<scope>/<file-name> |
Response
File is downloaded as a stream of bytes.
If the file doesn't exist, a 400 response code is returned and a FILE_NOT_FOUND message.
Get File Metadata
Returns the metadata associated with the requested file.
Request
The get file metadata GET request requires the storage unit name, the record key, the file scope and the file name (See putFile for upload info).
Code Block | ||||
---|---|---|---|---|
| ||||
GET access/getFileMetadata/<storage-unit>/<record-key>/<scope>/<file-name> |
Response
Returns a 200 response code and a JSON body with the file metadata.
Code Block | ||||
---|---|---|---|---|
| ||||
{
"title": "Logo",
"description": "logo-small"
} |
If the file doesn't exist, a 400 response code is returned and a FILE_NOT_FOUND message.