Skip to content

feat: Replace sync normalized-data with async flow (API-432)#46

Merged
hilnius merged 2 commits into
robinnicollet/api-431-sample-app-add-async_correction-support-for-dictate-wsfrom
robinnicollet/api-432-sample-app-replace-sync-normalized-data-with-async-flow
Jul 17, 2026
Merged

feat: Replace sync normalized-data with async flow (API-432)#46
hilnius merged 2 commits into
robinnicollet/api-431-sample-app-add-async_correction-support-for-dictate-wsfrom
robinnicollet/api-432-sample-app-replace-sync-normalized-data-with-async-flow

Conversation

@hilnius

@hilnius hilnius commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Replace the sync POST /generate-normalized-data call with the async submit + poll pattern (POST /generate-normalized-data-async + GET /generate-normalized-data-async/{id}).
  • Add a reusable pollUntilSucceeded helper in frontend/src/api/async-job.ts (10 s poll interval, uppercase job statuses).
  • Update the full-encounter demo docs badge and documentation link to point at the async endpoint.

Stacked on #45 (API-431) — merge that PR first.

Linear: https://linear.app/nabla/issue/API-432/sample-app-replace-sync-normalized-data-with-async-flow

Test plan

  • Full Encounter Demo → generate note → Extract normalized data completes successfully
  • Network tab shows POST .../generate-normalized-data-async followed by GET .../generate-normalized-data-async/{id} polls (~10 s apart)
  • Failed jobs (status: FAILED) stop polling and surface an error
  • Doc link opens the async endpoint documentation page

Showcase the recommended integration pattern for generate-normalized-data-async with a shared pollUntilSucceeded helper.

Co-authored-by: Cursor <cursoragent@cursor.com>
@hilnius hilnius self-assigned this Jul 15, 2026
@hilnius hilnius added the enhancement New feature or request label Jul 15, 2026
@hilnius
hilnius requested a review from AchrafAmil July 15, 2026 11:43
Comment thread frontend/src/api/async-job.ts
@hilnius
hilnius requested a review from AchrafAmil July 16, 2026 13:03

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit d3533d1. Configure here.

Comment thread frontend/src/api/async-job.ts
@hilnius
hilnius merged commit b4b53c5 into robinnicollet/api-431-sample-app-add-async_correction-support-for-dictate-ws Jul 17, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants