Skip to content

[BACK-4489] Add bulk patient account creation API. - #257

Open
lostlevels wants to merge 7 commits into
masterfrom
jp-bulk-patient-creation
Open

[BACK-4489] Add bulk patient account creation API.#257
lostlevels wants to merge 7 commits into
masterfrom
jp-bulk-patient-creation

Conversation

@lostlevels

Copy link
Copy Markdown
Contributor

No description provided.

@lostlevels
lostlevels requested a review from ewollesen August 6, 2026 14:27
Comment thread patients/bulk_create_patients.go Outdated
Comment thread auth/policy.rego
Comment thread patients/bulk_create_patients.go Outdated
Comment thread patients/bulk_create_patients.go Outdated
Comment thread patients/bulk_create_patients.go Outdated
Comment thread patients/bulk_create_patients.go Outdated
Comment thread patients/bulk_create_patients.go Outdated
Comment thread patients/bulk_create_patients.go
Comment thread patients/bulk_create_patients.go Outdated
Comment thread patients/bulk_create_patients.go Outdated
@lostlevels
lostlevels requested a review from ewollesen August 25, 2026 05:49
Comment thread patients/bulk_create_patients.go Outdated
Comment thread api/patients.go
return err
}
reader := csv.NewReader(ec.Request().Body)
reader.FieldsPerRecord = -1

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

You'll need the same change in the OpenAPI handler that's parsing the CSV body.

Name,Birthdate,MRN,Email
Ann Three,2000-01-01,MRN-RAG-003
Bob Four,2000-01-02,MRN-RAG-004,
Cat Five,2000-01-03,MRN-RAG-005,,type1
Dan Six,2000-01-04,MRN-RAG-006,,type2,adaStandard
Eve Seven,2000-01-05,MRN-RAG-007,,,,extra-ignored-column

The CSV above is rejected by the OpenAPI generated handler before it ever even hits the real handler.

A clinic integration test seems like a good idea.

Comment thread api/patients.go Outdated
Comment thread patients/bulk_create_patients.go Outdated
Comment thread patients/bulk_create_patients.go
Comment thread patients/bulk_create_patients.go
parsedPatient.Columns[OutputColEmailed] = "N"
}
} else {
_, err := patientSvc.Create(ctx, *parsedPatient.Patient)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I wonder how many patients can be created before the bulk creation request times out?

@ewollesen

Copy link
Copy Markdown
Contributor

Looks like a rebase is also required. :/

@lostlevels
lostlevels force-pushed the jp-bulk-patient-creation branch from 8218c44 to fef9f06 Compare September 10, 2026 07:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants