# Get Docs

This endpoint retrieves the Docs attached to the given Twin.

Method Path Operation*
GET /twins/{twin}/docs/ get_twin_docs

*

In order for a user to perform the "get_twin_docs" operation, the "get_twin_docs" permission must be included in the list of allowed actions in the statement of the user's role.

# Request

Parameter Type In Description
{twin}
required
string path Twin UUID.
view
optional *
string, value is tree or list, DEFAULT=list query string Allows choosing between a tree and a list view.
mask
optional *
string, DEFAULT=none query string Allows specifying files to be returned using regular expressions (opens new window).

*

The "view" and "mask" parameters are optional and do not need to be included in the request. If they are not included in the request, their default values are used.

In our example, we retrieve the Docs attached to the Twin with the Twin UUID 6cbb62f2-a837-44dd-b02b-4567d5888a4e.

# Response

The response returns a list of Docs attached to the Twin with the values of the "created_ts", "updated_ts", and "size" attributes.

Attribute Type Description
created_ts timestamp Time at which the Doc was attached to the Twin. Measured in seconds (to three decimal places) that have elapsed since the Unix epoch (opens new window).
updated_ts timestamp Time at which the Doc was last updated. Measured in seconds (to three decimal places) that have elapsed since the Unix epoch (opens new window).
size integer Size of the Doc in bytes.

# Status codes

Requests to this endpoint result in generic status codes. For a comprehensive list of status codes, please consult the Status Codes section.