API Reference¶
OpenTargetsClient¶
OpenTargetsClient(
base_url: str = "https://api.platform.opentargets.org/api/v4/graphql",
timeout: float = 30.0,
cache: bool = True,
cache_ttl: float = 300.0,
)
Target methods¶
Method |
Returns |
|---|---|
|
|
|
|
|
|
|
|
Disease methods¶
Method |
Returns |
|---|---|
|
|
|
|
Drug methods¶
Method |
Returns |
|---|---|
|
|
|
|
Search¶
Method |
Returns |
|---|---|
|
|
Associations¶
Method |
Returns |
|---|---|
|
|
Models¶
Target¶
id, approved_symbol, approved_name, biotype, description, function_descriptions
Disease¶
id, name, description, therapeutic_areas, db_x_refs
Drug¶
id, name, drug_type, mechanism_of_action, synonyms, trade_names, max_clinical_trial_phase
Association¶
target_id, target_symbol, disease_id, disease_name, score, datasource_scores, evidence_count
SearchResult¶
id, name, entity_type, description, score
DrugIndication¶
disease_id, disease_name, max_phase_for_indication
Exceptions¶
Exception |
When |
|---|---|
|
Base class |
|
HTTP error (non-2xx) |
|
GraphQL |
|
Entity not found |
|
HTTP 429 |