mLLMCelltype REST API Documentation

Integrate cell type annotation into your bioinformatics pipeline using the REST API.

Upload Marker Genes

POST /api/upload

Upload marker genes for cell type annotation. Supports CSV, TSV, and Excel formats.

Request

Parameter Type Description
file File Marker genes file (CSV, TSV, or Excel)

Example Request

curl -X POST https://www.mllmcelltype.com/api/upload \
  -H "Content-Type: multipart/form-data" \
  -F "file=@markers.csv"

Response

{
  "success": true,
  "task_id": "a1b2c3d4-...",
  "filename": "markers.csv",
  "file_info": {
    "shape": [20, 10],
    "columns": ["Cluster_0", "Cluster_1", "Cluster_2"],
    "preview": [{"Cluster_0": "CD3D", "Cluster_1": "CD14", "Cluster_2": "MS4A1"}]
  }
}

Start Annotation

POST /api/annotate

Start cell type annotation with selected models and parameters.

Request Body

Parameter Type Description
task_id String Task ID from upload response
species String Species (e.g., "human", "mouse")
tissue String Tissue type (optional)
models Array Model identifiers in "provider:model" format
api_keys Object Provider-to-API-key mapping

Example Request

{
  "task_id": "a1b2c3d4-...",
  "species": "human",
  "tissue": "PBMC",
  "models": ["openai:gpt-4o", "anthropic:claude-sonnet-4-20250514"],
  "api_keys": {
    "openai": "sk-...",
    "anthropic": "sk-ant-..."
  }
}

Check Status

GET /api/tasks/{task_id}

Check the status of an annotation task.

Response

{
  "task_id": "a1b2c3d4-...",
  "status": "completed",
  "progress": 100,
  "message": "Analysis completed successfully"
}

Download Sample Data

GET /api/sample

Download sample marker genes data for testing.

Rate Limits

API requests are limited to:

  • 1,000 requests per hour per IP (status polling excluded)
  • File size limit: 16 MB

Web Interface

Or use the web interface for interactive annotation

Open Web Interface