Read BLOB

Motivation

Retrieve the BLOB from the field of a document or record, using API

Functional design

GET /api/v2/apps/{owner}/{app}/workspaces/{wsid}/docs/{pkg}.{table}/{id}/blobs/{fieldName}

Headers / Cookies

Authorization is supported via Bearer token. The token can be passed in the Authorization header or as a cookie. The token is obtained during the authentication process.

Key
Value
Description

Authorization

Bearer {PrincipalToken}

The token obtained during the authentication process

Parameters

Parameter
Type
Description

owner

string

name of a user who owns the application

app

string

name of an application

wsid

int64

the ID of workspace

pkg, table

string

identifies a table (document or record)

id

int64

ID of a document or record

fieldName

string

name of the field containing the BLOB

Response Headers

Key
Value
Description

Content-Type

BLOB metadata

Returns the originally provided metadata

Blob-Name

BLOB name

Returns the originally provided name

Result

Code
Description
Body

200

OK

BLOB binary data

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

429

Too Many Requests

500

Internal Server Error

503

Service Unavailable

Technical design

Components

  • pkg/router

    • URL path handler ~cmp.routerBlobsReadPathHandler~✅:

  • pkg/sys/it

    • integration test for reading BLOBs

      • ~it.TestBlobsRead~

Last updated

Was this helpful?