diff --git a/CHANGELOG.md b/CHANGELOG.md index e4a7f66..143927f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## [2.0.8] - 2025-06-25 + +### Changed + +- Added `is_descending` parameters to `getParticipantAccounts` endpoint + ## [2.0.7] - 2025-06-11 ### Fixed diff --git a/package.json b/package.json index 38d1096..cbfb765 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@carp-dk/client", "type": "module", - "version": "2.0.7", + "version": "2.0.8", "description": "TypeScript API client for the CARP Web Services (CAWS).", "repository": { "type": "git", diff --git a/src/endpoints/study/recruitment.ts b/src/endpoints/study/recruitment.ts index 18d290c..458fbe9 100644 --- a/src/endpoints/study/recruitment.ts +++ b/src/endpoints/study/recruitment.ts @@ -81,17 +81,25 @@ class Recruitment extends Endpoint { offset, search, response_as_dto, + is_descending, }: { studyId: string; limit?: number | null; offset?: number | null; search?: string | null; response_as_dto?: boolean | null; + is_descending?: boolean | null; }) { const response = await this.actions.get< ParticipantAccount[] | PaginatedParticipantAccounts >(`${this.wsEndpoint}/${studyId}/participants/accounts`, { - params: { limit, offset, search, response_as_dto }, + params: { + limit, + offset, + search, + response_as_dto, + is_descending, + }, }); return response.data; diff --git a/src/test/endpoints/study/recruitment.test.ts b/src/test/endpoints/study/recruitment.test.ts index 22fcf3b..a932f36 100644 --- a/src/test/endpoints/study/recruitment.test.ts +++ b/src/test/endpoints/study/recruitment.test.ts @@ -148,6 +148,7 @@ describe("Recruitment", () => { offset: 0, search: null, response_as_dto: true, + is_descending: false, }); expect(accountInfo).toBeDefined();