Skills
Search compounds in Duaer
In Duaer, search compounds and drugs. One successful search uses 1 credit.
What Duaer returns
Each compound has a name, CID, formula, weight, SMILES, InChIKey, and related properties.
Key
Before you call, get a Duaer key.
Call skill
Paste this English skill into an agent. It matches Copy skill in the Duaer data market.
---
name: duaer-compounds
description: >-
Duaer compounds. PubChem compounds and drugs by name, CID, formula, SMILES, or InChIKey, with weight, structure, and drug-likeness properties.
One successful search uses 1 Duaer credit.
---
# Duaer compounds
Duaer compounds looks up PubChem compounds by one identifier and returns structure and computed properties.
## When to use
- Get the formula, weight, SMILES, and InChIKey of a drug by name.
- Check drug-likeness properties such as XLogP, TPSA, and hydrogen bond counts.
- Resolve an InChIKey or SMILES to a PubChem CID.
## When not to use
- Bioactivity against targets. Use https://skills.duaer.com/activities.md.
- Drug labels and indications. Use https://skills.duaer.com/drug-labels.md.
- Ids for one compound in other databases. Use https://skills.duaer.com/crossrefs.md.
## Call
`GET https://api.duaer.com/v1/data/compounds?name=aspirin&limit=10`
Header: `Authorization: Bearer <Duaer key>`
Use an account key or a model API key.
Get a Duaer key: https://skills.duaer.com/keys.md
## Parameters
Provide exactly one of `name`, `cid`, `formula`, `smiles`, or `inchikey`.
- `name` — Compound or drug name, such as `aspirin`. A name can match several compounds, up to `limit`.
- `cid` — PubChem compound id, such as `2244`.
- `formula` — Molecular formula, such as `C9H8O4`. Can match several compounds, up to `limit`.
- `smiles` — SMILES string. URL-encode it.
- `inchikey` — InChIKey, such as `BSYNRYMUTXBXSQ-UHFFFAOYSA-N`.
- `limit` — Optional. Rows to return, from 1 to 20. Default 10.
## Examples
- `GET https://api.duaer.com/v1/data/compounds?name=aspirin` — aspirin and close name matches.
- `GET https://api.duaer.com/v1/data/compounds?inchikey=BSYNRYMUTXBXSQ-UHFFFAOYSA-N` — one compound by InChIKey.
- `GET https://api.duaer.com/v1/data/compounds?formula=C9H8O4&limit=5` — compounds with one formula.
## Result
The response is `{ "items": [...] }`. Each item has `source` (`PubChem`), `title`, `url`, and `summary`, plus:
- `cid` — PubChem compound id.
- `formula`, `weight` — molecular formula and weight.
- `iupacName`, `smiles`, `inchi`, `inchiKey` — names and structure strings.
- `xlogp`, `tpsa` — computed lipophilicity and polar surface area.
- `hbondDonors`, `hbondAcceptors`, `rotatableBonds` — counts used in drug-likeness rules.
- `complexity`, `charge` — structural complexity and formal charge.
Reuse a compound name as `molecule` when searching activities: https://skills.duaer.com/activities.md.
Fields without a value are empty strings.
## Credits
A successful search uses 1 credit, even when it finds nothing.
A `name` that PubChem does not know, or an identifier PubChem answers with not found, returns no items and uses 0.
Wrong input, a missing identifier, or more than one identifier returns 400 with a message and uses 0.
A failed upstream search returns 503 and uses 0.
No remaining credits returns 402 and does not search.
A missing key returns 401.
## Related
- https://skills.duaer.com/trials.md — Duaer clinical trials
- https://skills.duaer.com/structures.md — Duaer structures
- https://skills.duaer.com/proteins.md — Duaer proteins
- https://skills.duaer.com/activities.md — Duaer activities
- https://skills.duaer.com/indications.md — Duaer indications
- https://skills.duaer.com/mechanisms.md — Duaer mechanisms
- https://skills.duaer.com/assays.md — Duaer assays
- https://skills.duaer.com/patents.md — Duaer patents
- https://skills.duaer.com/drug-gene.md — Duaer drug–gene
- https://skills.duaer.com/reactions.md — Duaer reactions
- https://skills.duaer.com/metabolites.md — Duaer metabolites
- https://skills.duaer.com/drug-labels.md — Duaer drug labels
- https://skills.duaer.com/adverse-events.md — Duaer adverse events
Related skills
Search clinical trials in Duaer
In Duaer, search clinical trials. One successful search uses 1 credit.
DataSearch protein structures in Duaer
In Duaer, search protein structures. One successful search uses 1 credit.
DataSearch proteins in Duaer
In Duaer, search genes and proteins. One successful search uses 1 credit.
DataSearch activities in Duaer
In Duaer, search ChEMBL bioactivities by molecule or target. One successful search uses 1 credit.
DataSearch indications in Duaer
In Duaer, search ChEMBL drug indications by molecule. One successful search uses 1 credit.
DataSearch mechanisms in Duaer
In Duaer, search ChEMBL mechanisms of action by molecule. One successful search uses 1 credit.
DataSearch assays in Duaer
In Duaer, search ChEMBL assays by words or assay id. One successful search uses 1 credit.
DataSearch patents in Duaer
In Duaer, search patents via Europe PMC. One successful search uses 1 credit.
DataSearch drug–gene interactions in Duaer
In Duaer, search drug–gene interactions via DGIdb. One successful search uses 1 credit.
DataSearch reactions in Duaer
In Duaer, search biochemical reactions via Rhea. One successful search uses 1 credit.
DataSearch metabolites in Duaer
In Duaer, search metabolites via ChEBI. One successful search uses 1 credit.
DataSearch drug labels in Duaer
In Duaer, search FDA drug labels via OpenFDA. One successful search uses 1 credit.
DataSearch adverse events in Duaer
In Duaer, search FDA adverse event reports via OpenFDA FAERS. One successful search uses 1 credit.