Skip to content

chore: ♻️ commonise REDCap API and JSON logic#154

Open
martonvago wants to merge 6 commits into
mainfrom
refactor/commonise-code
Open

chore: ♻️ commonise REDCap API and JSON logic#154
martonvago wants to merge 6 commits into
mainfrom
refactor/commonise-code

Conversation

@martonvago

Copy link
Copy Markdown
Collaborator

Description

This PR pulls out shared logic for using the REDCap API and (relatedly) reading/writing JSON.

This can be treated as groundwork for #153 if it's more helpful to review this first.

Needs a thorough review.

Checklist

  • Ran just run-all

Comment thread src/feasibility_data/common/redcap.py
Comment thread src/feasibility_data/metadata/redcap/core.py Outdated
@martonvago martonvago moved this from Todo to In review in Data development Jul 6, 2026
@martonvago
martonvago marked this pull request as ready for review July 6, 2026 09:13
@martonvago
martonvago requested a review from a team as a code owner July 6, 2026 09:14
@lwjohnst86 lwjohnst86 changed the title refactor: ♻️ commonise REDCap API and JSON logic chore: ♻️ commonise REDCap API and JSON logic Jul 8, 2026

@lwjohnst86 lwjohnst86 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

refactor, feat, fix tags are only used when data or metadata are changed in the PR. Since neither have been changed here, this is chore or some other tag.

Comment thread src/feasibility_data/common/redcap.py
Comment thread src/feasibility_data/common/json.py
Comment thread src/feasibility_data/common/redcap.py
Comment thread src/feasibility_data/common/redcap/api.py Outdated
Comment thread src/feasibility_data/data/redcap/raw.py
Comment thread src/feasibility_data/metadata/redcap/core.py Outdated
Comment thread src/feasibility_data/common/redcap/api.py Outdated
Comment thread src/feasibility_data/common/redcap/api.py Outdated
Comment thread src/feasibility_data/data/redcap/raw.py Outdated
Comment thread src/feasibility_data/data/redcap/raw.py Outdated
@github-project-automation github-project-automation Bot moved this from In review to In progress in Data development Jul 8, 2026
Test = APIConfig(env_key="TEST_API_KEY", url="https://redcap.au.dk/api/")


def get(

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Called it get because get_request was a bit confusing because we are sending a POST request and getting a response. But moved to request_data as a param name.

@martonvago martonvago moved this from In progress to In review in Data development Jul 8, 2026
@martonvago
martonvago requested a review from lwjohnst86 July 8, 2026 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In review

Development

Successfully merging this pull request may close these issues.

2 participants