Skip to main content
POST
/
plants
/
search
cURL
curl --request POST \
  --url http://localhost:3001/plants/search \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "namePattern": "Monstera",
  "tag": "tropical",
  "minSize": 50
}
'
[
  {
    "name": "Monstera Deliciosa",
    "tag": "<string>",
    "related_plants": [
      {
        "name": "<string>"
      }
    ]
  }
]

Authorizations

Authorization
string
header
required

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

Body

application/json

Search criteria - matches plants meeting any of the conditions

Search criteria - plant must match at least one of the specified conditions

namePattern
string
required

Pattern to match against plant names

Example:

"Monstera"

tag
string

Tag to filter by

Example:

"tropical"

minSize
number

Minimum size in cm

Example:

50

Response

Search results

name
string
default:Monstera Deliciosa
required

The name of the plant

tag

Pure-string tag to specify the type

Related plants

Plant name