Skip to main content
GET
/
plants
/
{id}
/
hierarchy
cURL
curl --request GET \
  --url http://localhost:3001/plants/{id}/hierarchy \
  --header 'Authorization: Bearer <token>'
{
  "id": 123,
  "name": "<string>",
  "parent": "<unknown>",
  "children": "<array>",
  "siblings": "<array>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
integer<int64>
required

ID of the plant

Response

Plant hierarchy with circular references

Plant with hierarchical relationships - demonstrates circular reference

id
integer<int64>
required

Unique identifier for the plant

name
string
required

Name of the plant

parent
object

Parent plant

children
array

Child plants

siblings
array

Sibling plants