1. Introduction
The GeDiPNet REST API provides programmatic access to curated gene-disease-pathway associations, regulatory networks, and biological annotations. Use it to:
- Query gene information including diseases, pathways, transcription factors, miRNAs, and variants
- Retrieve disease records with associated genes, external database IDs (MeSH, OMIM, HPO, Orphanet, MONDO), and PubMed evidence
- Access pathway data from Reactome and KEGG
- Download complete datasets in TSV or JSON for offline analysis
- Build custom bioinformatics pipelines and integrate GeDiPNet data into your workflows
2. Base URL
https://gedipnet.bicnirrh.res.in/api
All endpoints are relative to this base URL. For example:
https://gedipnet.bicnirrh.res.in/api/genes/BRCA1
3. Authentication
API Key Required: All endpoints (except the /test health check) require a valid API key. Keys are free and issued instantly upon registration.
Log in to Get Your Free API Key
How to send your key
| Method | How to send | Recommended? |
| Request header |
X-API-Key: your-key-here |
Yes — preferred |
| Query parameter |
?api_key=your-key-here |
Fallback only |
| Interactive console below |
Click Authorize (top right of the console) and paste your key |
Yes — for browser testing |
Getting your key in 3 steps
Step 1 — Register / Log in
Visit login.php and create a free account or log in with your existing credentials.
Step 2 — Generate Key
On your profile dashboard, click "Generate My API Key". Your unique key is created instantly.
Step 3 — Check Your Email
Your key is sent to your registered email address immediately.
4. Request Format
All API requests follow standard REST principles:
- HTTP Methods: GET for retrieving data, POST for bulk operations
- Content-Type: application/json (for POST requests)
- Response Format: JSON
- Character Encoding: UTF-8
Example GET Request:
curl -X GET "https://gedipnet.bicnirrh.res.in/api/genes/BRCA1" \
-H "X-API-Key: your-key-here" \
-H "accept: application/json"
Example POST Request:
curl -X POST "https://gedipnet.bicnirrh.res.in/api/diseases/bulk" \
-H "X-API-Key: your-key-here" \
-H "Content-Type: application/json" \
-d '{"diseases": ["breast cancer", "diabetes mellitus"]}'
Example in Python:
import requests
headers = {"X-API-Key": "your-key-here"}
r = requests.get("https://gedipnet.bicnirrh.res.in/api/genes/BRCA1", headers=headers)
print(r.json())
Example in R:
library(httr)
library(jsonlite)
res <- GET("https://gedipnet.bicnirrh.res.in/api/genes/BRCA1",
add_headers("X-API-Key" = "your-key-here"))
data <- fromJSON(content(res, "text"))
5. Response Format
All successful responses return JSON with a consistent envelope:
{
"status": "success",
"data": { ... },
"count": 123,
"pagination": { "page": 1, "has_next": true, ... }
}
Top-level fields
- status —
"success" or "error"
- data — the payload; shape varies by endpoint
- count — total records available (paginated endpoints)
- pagination — page/offset info and
has_next / has_prev flags
Disease response fields
- disease_ids — array of { id, database, url } objects (MeSH, OMIM, HPO, Orphanet, MONDO, UMLS, MedGen)
- main_sources — array of evidence source labels, e.g.
["Disgenet", "Orphanet"]
- references — array of { pmid, url } objects linking to PubMed
6. Error Handling
Errors return the appropriate HTTP status code and a JSON body:
| HTTP Code | Meaning | Example Scenario |
| 400 | Bad Request | Invalid parameter format or missing required field |
| 401 | Unauthorized | No API key was sent with the request |
| 403 | Forbidden | API key is invalid or has been revoked |
| 404 | Not Found | Requested gene, disease, or pathway does not exist |
| 422 | Unprocessable Entity | Valid format but semantic error (e.g. unknown gene symbol) |
| 429 | Too Many Requests | Rate limit exceeded — 100 requests/hour per key |
| 500 | Internal Server Error | Unexpected server or database failure |
| 503 | Service Unavailable | Temporary maintenance or database connection issue |
{
"status": "error",
"message": "Gene 'XYZ123' not found in database",
"code": 404
}
7. Rate Limits
Limit: Each API key is restricted to 100 requests per hour. Exceeding this returns HTTP 429 with a retry_after_seconds field.
Rate limit headers
Every response includes these headers:
| Header | Meaning |
X-RateLimit-Limit | Your ceiling — always 100 |
X-RateLimit-Remaining | Requests left in the current window |
X-RateLimit-Reset | Unix timestamp when your counter resets |
Best practices:
- Use POST /diseases/bulk to query up to 50 diseases in one request
- Use download endpoints for large exports — one request per batch
- Cache responses locally when running repeated analyses
- Add a 100–300 ms delay between sequential requests in scripts
- Need higher limits? Contact gedipnet@bicnirrh.res.in
8. How to Use the Interactive Console
The console below is powered by Swagger UI — test any endpoint directly from your browser without writing code.
Before you start: You need an API key.
Log in to your profile to generate one instantly. Then click the
Authorize button at the top right of the console, paste your key, and click Authorize.
1 Authorize
Click "Authorize" at the top right, paste your X-API-Key, and confirm. Only needed once per session.
2 Select Endpoint
Click any endpoint row to expand its parameters, schema, and example response.
3 Try It Out
Click "Try it out" to enable the input fields.
4 Fill Parameters
Enter required values (marked *). Example values are pre-filled to help you get started.
5 Execute
Click "Execute" to fire the request. You'll see the full URL, a ready-to-copy cURL command, status code, and JSON response.
Tip: Copy the generated cURL command and adapt it for Python (requests), R (httr), or any other language to integrate GeDiPNet data into your pipeline.