Loading...
Loading...
Compare original and translation side by side
https://reactome.org/ContentServicehttps://reactome.org/ContentServicehttps://reactome.org/AnalysisServicehttps://reactome.org/AnalysisServiceuv pip install reactome2pyuv pip install reactome2pyimport requests
response = requests.get("https://reactome.org/ContentService/data/database/version")
version = response.text
print(f"Reactome version: {version}")import requests
entity_id = "R-HSA-69278" # Example pathway ID
response = requests.get(f"https://reactome.org/ContentService/data/query/{entity_id}")
data = response.json()import requests
event_id = "R-HSA-69278"
response = requests.get(
f"https://reactome.org/ContentService/data/event/{event_id}/participatingPhysicalEntities"
)
molecules = response.json()import requests
response = requests.get("https://reactome.org/ContentService/data/database/version")
version = response.text
print(f"Reactome version: {version}")import requests
entity_id = "R-HSA-69278" # Example pathway ID
response = requests.get(f"https://reactome.org/ContentService/data/query/{entity_id}")
data = response.json()import requests
event_id = "R-HSA-69278"
response = requests.get(
f"https://reactome.org/ContentService/data/event/{event_id}/participatingPhysicalEntities"
)
molecules = response.json()import reactome2py
from reactome2py import contentimport reactome2py
from reactome2py import content
**For detailed API endpoints and parameters**, refer to `references/api_reference.md` in this skill.
**如需详细的API端点和参数**,请参考本技能中的`references/api_reference.md`文档。import requestsimport requests
**Retrieve analysis by token:**
```python
**通过令牌检索分析结果:**
```pythonundefinedundefined#Gene Sample1 Sample2 Sample3
TP53 2.5 3.1 2.8
BRCA1 1.2 1.5 1.3
EGFR 4.5 4.2 4.8import requests#Gene Sample1 Sample2 Sample3
TP53 2.5 3.1 2.8
BRCA1 1.2 1.5 1.3
EGFR 4.5 4.2 4.8import requestsundefinedundefined/projection/response = requests.post(
"https://reactome.org/AnalysisService/identifiers/projection/",
headers={"Content-Type": "text/plain"},
data=data
)/projection/response = requests.post(
"https://reactome.org/AnalysisService/identifiers/projection/",
headers={"Content-Type": "text/plain"},
data=data
)token = result["summary"]["token"]
pathway_id = "R-HSA-69278"
url = f"https://reactome.org/PathwayBrowser/#{pathway_id}&DTAB=AN&ANALYSIS={token}"
print(f"View results: {url}")token = result["summary"]["token"]
pathway_id = "R-HSA-69278"
url = f"https://reactome.org/PathwayBrowser/#{pathway_id}&DTAB=AN&ANALYSIS={token}"
print(f"查看结果:{url}")GET /token/{TOKEN}GET /token/{TOKEN}pathwayssummaryentitiespathwayssummaryentitiesscripts/reactome_query.pyundefinedscripts/reactome_query.pyundefinedundefinedundefinedreferences/api_reference.mdreferences/api_reference.md