# AI好医生 Partner SDK sample

Tiny read-only client for the public Partner API.

**Rules**

- Audience: licensed clinicians only (not patient self-diagnosis).
- API returns **catalog + cite links** only.
- **Never** compute clinical scores in your backend.
- **Never** send PHI / patient identifiers to these endpoints.
- Always surface the returned `disclaimer` to end users.
- Calculations stay on live tool pages (browser-local).

## Endpoints

| Method | URL | Purpose |
|--------|-----|---------|
| GET | `/api/v1/health` | Liveness `{ ok, brand, updated }` |
| GET | `/api/v1/tools` | Same payload as `/for-ai/tools.json` |
| GET | `/api/v1/cite?q=...` | Resolve phrase → tool/scene/app links |

CORS: `Access-Control-Allow-Origin: *` on these GET routes (OPTIONS supported).

## Node / Deno / browser (ESM)

```js
import { listTools, cite } from "https://aihaoyisheng.com/for-ai/sdk/aihaoyisheng-cite.mjs";

const healthish = await cite("qSOFA");
console.log(healthish.matches, healthish.disclaimer);

const catalog = await listTools();
console.log(catalog.count, catalog.disclaimer);
```

Or download `aihaoyisheng-cite.mjs` and import locally.

## Demo

Open [example.html](./example.html) (calls `cite('qSOFA')` and renders result links).

## Related

- Developers hub: https://aihaoyisheng.com/developers
- OpenAPI: https://aihaoyisheng.com/for-ai/openapi.json
- Cite map: https://aihaoyisheng.com/for-ai/cite-map.json
- Skill: https://aihaoyisheng.com/for-ai/SKILL.md
- App (Android APK; Harmony HAP pending): https://aihaoyisheng.com/app
