Client application metadata (metadata)

Resources representing metadata/schemas for operation and automatic adjustment of external applications to the server data structure.

Requests

HTTP verb Endpoint Description

GET

/rest/v1/metadata

Directory contents

GET

/rest/v1/metadata/<path>

Directory contents or asset file

Domain type: any.

Group structure

This endpoint group provides access to assets located in the era_env/priv/rest_metadata/…​ directory at any nesting level.

Each such asset is addressed directly via a separate endpoint and can be overridden by rights at the user role level (determined by the iam.json and iam_all.json assets).

A request to an endpoint authorized in a domain of type SOLUTION ('master' or 'era') returns a file from the corresponding directory

/era_env/priv/rest_metadata/solutions/<SOLUTION>

and if it is not there, from the common directory

/era_env/priv/rest_metadata/common

Example

Suppose the following request is made in a domain of type era:

Request:
GET /rest/v1/metadata/a/b/c/d.json
Returned file placement in descending priority:
/era_env/priv/rest_metadata/solutions/era/a/b/c/d.json

/era_env/priv/rest_metadata/common/a/b/c/d.json

Directory contents

If the path points to a directory, a merged list of its elements from the solution directory and the common directory is returned (without duplicates, by name): name, for a directory — type: "directory", for a file — size in bytes. If the path points to a file, the file is returned with content type by extension. Missing path — 404.

Example response
GET /rest/v1/metadata HTTP/1.1

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

[
  {"name": "forms", "type": "directory"},
  {"name": "menu.json", "size": 2048}
]