top of page

Read data

GET /<org_name>/<path>/<data_item_name>.data

Data Items


For data, Registry is a key-value store of registers (a.k.a., data items).  A client can write, delete, and read small blobs of 100 KB (configurable) or smaller.  Blobs can be overwritten or deleted, but not edited in other ways.  When a blob is written, its content type (specified by Content-Type header) is saved, and it is returned along with the blob when read.  The service only looks at the blob’s size but does not look into its contents, not even for checksumming.  If the client desires encryption, checksumming, or error-correcting of their data, they need to do those at the client side.



Request

Example

GET /<org_name>/<path>/<data_item_name>.data
Host: <service_address>
Authorization: <org_key>

GET /sample_org/nemmies/rolls/recipe.data
Host: beta.useast2.registry.dkplatform.io
Authorization: randomAlphaNumericString

Param
Meaning
Authorization
The credential showing the client's permission for the request. It is the `org_key` of the org.
Host
The service address, such as "useast2.registry.dkplatform.io".
x-dk-org-time
A response header that shows the org_time after the request is executed.
x-dk-create-org-time
A response header that returns a data item's create-org-time.
x-dk-update-org-time
A response header that returns a data item's update-org-time.

Response

200 OK

Content-Type: <string>

x-dk-org-time: <u64>

x-dk-create-org-time: <u64>

x-dk-update-org-time: <u64>

Body is Data

Success. The stored content is returned in the body. The stored content type is returned in the Content-Type header.

400 BAD REQUEST

Wrong format in org, path, or data item name.  Missing Authorization header, or Authorization header is empty.

404 NOT FOUND


There is no such org, data item, or (for confidentiality concern) the secret token is invalid.

500 INTERNAL SERVER ERROR

An unexpected error happened at the server.


© 2024 by DK Lab.

bottom of page