Get a canon facet
Módulo Canon
GET/canon/facets/{facet}canonFacets.get
A facet carried from canon. Returns one canon facet with its `ETag`. A canon facet the caller may not see returns 404.
- Requiere la capacidad canon.taxonomy.read.
- Alcances de OAuth: canon.
- Estados de error: 400, 401, 404, 429. Los errores son detalles de problema RFC 9457.
Parámetros de ruta y de consulta
| Campo | Tipo | Obligatorio | Descripción |
|---|---|---|---|
| facet | string | Sí | Facet name.Restricciones: length 1 to 200 |
| fields | Fields | No | Sparse fieldset: a comma-separated list of top-level fields to return. `id` is always returned.Restricciones: pattern ^[a-z_][a-z0-9_]*(,[a-z_][a-z0-9_]*)*$ |
Respuesta 200: CanonFacet
| Campo | Tipo | Obligatorio | Descripción |
|---|---|---|---|
| facet | string | Sí | Facet name.Restricciones: length 1 to 200 |
| form | string | null | Sí | Form of the facet.Restricciones: length 1 to 300 |
| rolls_up_to | string | null | Sí | What the facet rolls up to.Restricciones: length 1 to 200 |
| since | string | null | Sí | Version that introduced it, as written in canon.Restricciones: length 1 to 64 |
| note | string | null | Sí | Note from the Bible.Restricciones: length 1 to 20000 |
{
"facet": "Phase",
"form": "Nine gated phases",
"rolls_up_to": "Act",
"since": "3.0",
"note": "Carried from canon."
}Ejemplos de código
curl -X GET "$XOS_BASE_URL/canon/facets/Phase" \
-H "Authorization: Bearer $XOS_API_KEY"const { data, etag } = await xos.canonFacets.get("Phase");response = xos.canon_facets.get("Phase")xos canon-facets get Phase