Sample - Box Platform API
GET/metadata_templates/{namespace}/{template_key}/fields/{field_key}/options

List metadata template's options for taxonomy field

Used to retrieve metadata taxonomy nodes which are available for the taxonomy field based on its configuration and the parameters specified. Results are sorted in lexicographic order unless a query parameter is passed. With a query parameter specified, results are sorted in order of relevance.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

11 parameters
namespacestringrequired
The namespace of the metadata taxonomy.
template_keystringrequired
The name of the metadata template.
field_keystringrequired
The key of the metadata taxonomy field in the template.
levelarray<integer>optional
Filters results by taxonomy level. Multiple values can be provided. Results include nodes that match any of the specified values.
parentarray<string>optional
Node identifier of a direct parent node. Multiple values can be provided. Results include nodes that match any of the specified values.
ancestorarray<string>optional
Node identifier of any ancestor node. Multiple values can be provided. Results include nodes that match any of the specified values.
querystringoptional
Query text to search for the taxonomy nodes.
include-total-result-countbooleanoptional
When set to `true` this provides the total number of nodes that matched the query. The response will compute counts of up to 10,000 elements. Defaults to `false`.
only-selectable-optionsbooleanoptional
When set to `true`, this only returns valid selectable options for this template taxonomy field. Otherwise, it returns all taxonomy nodes, whether or not they are selectable. Defaults to `true`.
markerstringoptional
Defines the position marker at which to begin returning results. This is used when paginating using marker-based pagination. This requires `usemarker` to be set to `true`.
limitintegeroptional
The maximum number of items to return per page.

3 status codes
200Returns a list of the taxonomy nodes that match the specified parameters.
limitintegeroptional
The limit that was used for these entries. This will be the same as the `limit` query parameter unless that value exceeded the maximum value allowed. The maximum value varies by API.
next_markerstringoptional
The marker for the start of the next page of results.
prev_markerstringoptional
The marker for the start of the previous page of results.
entriesarray<MetadataTaxonomyNode>optional
A list of metadata taxonomy nodes.
400Returned when the request parameters are not valid.
typestringoptional
The value will always be `error`.
Allowed:error
statusintegeroptional
The HTTP status of the response.
codestringoptional
A Box-specific error code.
Allowed:createdacceptedno_contentredirectnot_modifiedbad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictprecondition_failed
messagestringoptional
A short message describing the error.
context_infoobjectoptional
A free-form object that contains additional context about the error. The possible fields are defined on a per-endpoint basis. `message` is only one example.
help_urlstringoptional
A URL that links to more information about why this error occurred.
request_idstringoptional
A unique identifier for this response, which can be used when contacting Box support.
defaultAn unexpected client error.
typestringoptional
The value will always be `error`.
Allowed:error
statusintegeroptional
The HTTP status of the response.
codestringoptional
A Box-specific error code.
Allowed:createdacceptedno_contentredirectnot_modifiedbad_requestunauthorizedforbiddennot_foundmethod_not_allowedconflictprecondition_failed
messagestringoptional
A short message describing the error.
context_infoobjectoptional
A free-form object that contains additional context about the error. The possible fields are defined on a per-endpoint basis. `message` is only one example.
help_urlstringoptional
A URL that links to more information about why this error occurred.
request_idstringoptional
A unique identifier for this response, which can be used when contacting Box support.

Error handling

A 400 is returned: Returned when the request parameters are not valid. Any other status is an error: An unexpected client error.