Learn how to integrate your practice management system with Askara to receive clinical notes automatically when they are generated from audio transcriptions.
When a healthcare professional records an audio consultation in Askara, the system transcribes it and generates a clinical note using AI. Your system can receive these notes automatically via webhook or retrieve them by polling the API.
- Receive notification - Via webhook (push) or polling (pull)
- Retrieve note - Get note content and metadata via API
- Import to your system - Save the note in your database
Webhooks provide real-time notifications when notes are generated. Askara sends an HTTP POST request to your endpoint.
Advantages:
- Real-time synchronization
- No polling overhead
- Efficient resource usage
Endpoint: POST /webhooks
-> API Reference: Create Webhook
{
"url": "https://your-system.com/api/askara/webhook",
"events": ["new_note"],
"active": true
}When a note is generated, Askara sends a POST request to your webhook URL.
Webhook Payload Structure:
{
"events": [{
"id": "note-uuid",
"resource_type": "note",
"action": "new_note",
"metadata": {
"note": {
"uuid": "...",
"type": "consultation_summary",
"content": "Patient presents with...",
"createdAt": "2026-02-24T10:30:00+00:00",
"updatedAt": "2026-02-24T10:30:00+00:00",
"patient": { "uuid": "...", "firstName": "...", "lastName": "..." }
}
},
"resource_metadata": {
"user_id": "...",
"organization_id": "..."
}
}],
"meta": {
"webhook_id": "your-webhook-uuid"
}
}Important:
- Respond with
200 OKwithin 5 seconds - Process the note asynchronously (don't block the response)
- Use the note
uuidfor deduplication if the webhook is retried
If you need additional data not included in the webhook payload (e.g., associated audio or user information), fetch the full note via API.
Endpoint: GET /notes/{uuid}
If webhooks aren't feasible, poll periodically for new notes.
Endpoint: GET /notes
Useful query parameters:
patient=<patient-uuid>- Filter by patientaudio=<audio-uuid>- Filter by source audiocreatedAt[after]=2026-02-17- Filter by creation dateorder[createdAt]=desc- Sort by newest first
Recommended polling interval: 30-60 seconds
If your webhook endpoint fails to respond (network error, timeout, non-2xx status code), Askara automatically retries delivery:
- Retry 1: After 5 seconds
- Retry 2: After 10 seconds
- Retry 3: After 20 seconds
- Max retries: 3 attempts
After 3 failed attempts, the webhook delivery is marked as failed and stored in the failure queue.
To synchronize notes, your OAuth2 client must request this scope:
read:notes- Retrieve note information
app.post('/api/askara/webhook', async (req, res) => {
// Respond quickly to avoid timeout
res.status(200).send('OK');
const events = req.body.events;
// Process asynchronously
for (const event of events) {
if (event.action === 'new_note') {
const note = event.metadata.note;
try {
// Import note to your system
await saveToSystem({
uuid: note.uuid,
content: note.content,
patientUuid: note.patient?.uuid,
createdAt: note.createdAt
});
console.log(`Successfully imported note ${note.uuid}`);
} catch (error) {
console.error(`Failed to import note ${note.uuid}:`, error);
}
}
}
});- Process asynchronously - Don't block webhook responses while processing
- Handle duplicates - Use note UUID to prevent duplicate imports
- Implement idempotency - Same note UUID should produce the same result
- Log failures - Include detailed error information for troubleshooting
- Verify your webhook URL is publicly accessible
- Check that your endpoint responds with
200 OKwithin 5 seconds - Review webhook logs in Askara dashboard
- Ensure your firewall allows Askara's IP addresses
- Check OAuth2 token hasn't expired
- Verify you have the
read:notesscope - Confirm the audio transcription has completed before expecting a note
- API Reference - Explore all endpoints
- Document Synchronization - Synchronize validated documents
- OAuth2 Authentication - Secure your integration
- Rate Limiting - Understand API limits