Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Link API Endpoint #79

Merged
merged 2 commits into from
Oct 17, 2024
Merged

New Link API Endpoint #79

merged 2 commits into from
Oct 17, 2024

Conversation

cbrinson-rise8
Copy link
Contributor

@cbrinson-rise8 cbrinson-rise8 commented Oct 16, 2024

Description

Create a new API endpoint, /link, that behaves similar to the existing /link-record endpoint. The difference is that it will accept a raw PII payload rather than a FHIR bundle.

Related Issues

closes #5

Additional Notes

Overview of changes

  • Adds a new endpoint /link
  • Adds tests for new endpoint
  • updates src.recordlinker.linking.link.link_record_against_mpi function to accept a schemas.PIIRecord instead of a FHIR bundle.
  • src.recordlinker.linking.link.link_record_against_mpi now returns a patient_reference_id in addition to the other values in the returned tuple
  • Adds patient_reference_id column to patient mpi table
  • Renames internal_id column to person_reference_id in the person mpi table

<--------------------- REMOVE THE LINES BELOW BEFORE MERGING --------------------->

Checklist

Please review and complete the following checklist before submitting your pull request:

  • I have ensured that the pull request is of a manageable size, allowing it to be reviewed within a single session.
  • I have reviewed my changes to ensure they are clear, concise, and well-documented.
  • I have updated the documentation, if applicable.
  • I have added or updated test cases to cover my changes, if applicable.
  • I have minimized the number of reviewers to include only those essential for the review.
  • I have notified teammates in the review thread to build awareness.

Checklist for Reviewers

Please review and complete the following checklist during the review process:

  • The code follows best practices and conventions.
  • The changes implement the desired functionality or fix the reported issue.
  • The tests cover the new changes and pass successfully.
  • Any potential edge cases or error scenarios have been considered.

@cbrinson-rise8 cbrinson-rise8 self-assigned this Oct 16, 2024
@cbrinson-rise8 cbrinson-rise8 added the feature New feature or request label Oct 16, 2024
Copy link

codecov bot commented Oct 16, 2024

Codecov Report

Attention: Patch coverage is 90.90909% with 3 lines in your changes missing coverage. Please review.

Project coverage is 92.61%. Comparing base (cbe8c78) to head (6116cff).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/recordlinker/main.py 88.88% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #79      +/-   ##
==========================================
- Coverage   92.75%   92.61%   -0.15%     
==========================================
  Files          17       17              
  Lines         759      785      +26     
==========================================
+ Hits          704      727      +23     
- Misses         55       58       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@cbrinson-rise8 cbrinson-rise8 force-pushed the feat/new-link-api-endpoint branch 3 times, most recently from eb881cf to 958337b Compare October 16, 2024 20:50
@cbrinson-rise8 cbrinson-rise8 marked this pull request as ready for review October 16, 2024 20:50
@cbrinson-rise8 cbrinson-rise8 changed the title Feat/new link api endpoint New Link API Endpoint Oct 16, 2024
@cbrinson-rise8 cbrinson-rise8 force-pushed the feat/new-link-api-endpoint branch from 6c2092c to 2ca6a95 Compare October 17, 2024 15:05
@cbrinson-rise8 cbrinson-rise8 force-pushed the feat/new-link-api-endpoint branch from 2ca6a95 to 96bfd65 Compare October 17, 2024 15:06
ericbuckley
ericbuckley previously approved these changes Oct 17, 2024
Copy link
Collaborator

@ericbuckley ericbuckley left a comment

Choose a reason for hiding this comment

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

nice work, that was easier than I thought it be!

Co-authored-by: Eric Buckley <eric.buckley@gmail.com>
@cbrinson-rise8 cbrinson-rise8 merged commit 327d2f8 into main Oct 17, 2024
7 checks passed
@cbrinson-rise8 cbrinson-rise8 deleted the feat/new-link-api-endpoint branch October 17, 2024 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New /link API endpoint
2 participants