Interested in joining a scientific study?Learn more

Utility API

Get Decode Compound ID API

Available

Get Decode Compound ID searches compound identifiers by name and returns IDs that can be used in compound-level filters and advanced nutrition workflows.

GET/functions/v1/get_decode_compound_id?q=caffeine&limit=20

Inputs

  • q query parameter for compound search
  • Optional limit query parameter from 1 to 100

Returns

  • compound_id
  • compound_name
  • compound_identifier_value

Request

GET /functions/v1/get_decode_compound_id?q=caffeine&limit=20

Response JSON

{
  "items": [
    {
      "compound_id": "cmp_123",
      "compound_name": "Caffeine",
      "compound_identifier_value": "C8H10N4O2"
    }
  ]
}
curl 'https://tirqjzahcinadeulfylj.supabase.co/functions/v1/get_decode_compound_id?q=caffeine&limit=20' \
  -H 'x-api-key: $MYMOLECULES_API_KEY'