Você está integrando a API pública da Telepatia Synapse.
Endpoint: GET /v1/medical-record-configurations
Base URL: https://scribe-api.telepatia.ai
Auth: Authorization: Bearer ${SYNAPSE_API_KEY}
Requisição:
- page [query]: integer (opcional, min=1) — Page number (1-based).
- limit [query]: integer (opcional, min=1, max=50) — Number of items per page.
- status [query]: string (opcional, enum: deleted, all) — Filter for the templates list view: `deleted` (only soft-deleted templates) or
`all` (non-deleted and deleted). Omit for the default non-deleted view.
- workflow [query]: string (opcional, enum: defaultOutpatient, inpatient, emergencyRoom, reportDictation, historySummary) — Product discriminator for a template. Absent means an ordinary Scribe template.
`defaultOutpatient`, `inpatient`, and `emergencyRoom` also denote a Scribe
template; each names the clinical care setting the template is written for.
`reportDictation` and `historySummary` denote a non-Scribe product.
Sucesso 200:
- items: array<MrcSummary>
- total: integer
- page: integer
- limit: integer
- totalPages: integer
Erros (envelope: { error: { type, code, message, param? } }):
- 400: parameter_missing, parameter_invalid, account_invalid
- 401: authentication_required
- 428: cdss_review_required
- 503: service_unavailable
Gere código na linguagem do arquivo atual que:
1. Leia SYNAPSE_API_KEY do ambiente (não fixe o valor no código).
2. Chame o endpoint com requisição e resposta tipadas.
3. Mapeie o envelope de erros para exceções tipadas por código de status.
4. Adicione um teste de caminho feliz usando o token Bearer.