跳到主要内容

getTemplates

MetadataTemplateArrayWrapper getTemplates(visible)

GET /api/2.0/files/metadata/templates

Get metadata templates

Lists the metadata templates of the portal with their fields, the dictionary a file, a folder or a room is described with. Any member of the portal can read it, the list is the same for everyone. The call is read-only. The templates come back ordered by their creation, each with its fields in their display order and the choice options of the choice fields; the visible parameter narrows the list to the templates shown in the pickers or to the hidden ones, without it both are returned. An empty list means the portal has no templates yet. The custom text fields set on the entries are not templates and are not listed here: read them on the entry with GET api/2.0/files/metadata/file/{fileId}.

Parameters​

NameInTypeDescriptionNotes
visiblequeryBooleanFilters the templates by their visibility.[optional] [example: true]

Responses​

Status codeDescriptionTypeResponse headers
200List of metadata templatesMetadataTemplateArrayWrapperX-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset
401UnauthorizedErrorApiResponse-
429Too Many Requests.ErrorApiResponseRetry-After
500Internal Server Error.ErrorApiResponse-
400Bad Request.ErrorApiResponse-
502Bad Gateway. Returned by the reverse proxy, response body may be HTML and not JSON.--
503Service Unavailable. Returned by the reverse proxy, response body may be HTML and not JSON.--

Return type​

MetadataTemplateArrayWrapper

Authorization​

Basic, OAuth2 (scopes: read, write), ApiKeyBearer, asc_auth_key, Bearer, OpenId

HTTP request headers​

  • Content-Type: Not defined
  • Accept: application/json