๐ŸŽ‰ 30% OFF Pro PlanClaim Now

API Documentation

Complete guide to using Dr7.ai Medical API

Quick Start

API Endpoints

Authentication

Dr7.ai Medical API uses API keys for authentication. Include your API key in the Authorization header:

Authorization: Bearer sk-dr7-your-api-key

Note: Keep your API key secure and never expose it in client-side code. You can manage your API keys in the dashboard.

Medical Chat Completions

POST/v1/medical/chat/completions

Generate medical responses based on symptoms and medical queries

Request

curl https://api.dr7.ai/v1/medical/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer sk-dr7-your-api-key" \
  -d '{
    "model": "medgemma-4b-it",
    "messages": [
      {
        "role": "user",
        "content": "ๆ‚ฃ่€…ไธป่ฏ‰ๅคด็—›3ๅคฉ๏ผŒไผดๆœ‰ๅ‘็ƒญ38.5ยฐC"
      }
    ],
    "max_tokens": 1000,
    "temperature": 0.7
  }'

Response

{
  "id": "med-1234567890",
  "object": "medical.chat.completion",
  "created": 1677652288,
  "model": "medgemma-4b-it",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "ๆ นๆฎๆ‚จๆ่ฟฐ็š„็—‡็Šถ๏ผŒๆ‚ฃ่€…ๅ‡บ็Žฐๅคด็—›ไผดๅ‘็ƒญ๏ผŒ้œ€่ฆ่€ƒ่™‘ไปฅไธ‹ๅฏ่ƒฝ็š„่ฏŠๆ–ญ..."
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 25,
    "completion_tokens": 150,
    "total_tokens": 175
  }
}

Error Handling

The API uses standard HTTP status codes and returns error details in JSON format:

{
  "error": {
    "message": "Invalid API key provided",
    "type": "authentication_error",
    "code": "invalid_api_key"
  }
}
Status CodeDescription
401Invalid or missing API key
402Insufficient account balance
429Rate limit exceeded
500Internal server error

Pricing

Our API uses token-based pricing. You only pay for what you use.

ModelInputOutput
medgemma-4b-it$0.001 / 1K tokens$0.002 / 1K tokens
medgemma-27b-it$0.003 / 1K tokens$0.006 / 1K tokens
medsiglip-v1$0.005 / image$0.002 / 1K tokens