diff --git a/.fernignore b/.fernignore index 0ced819c2..958d4e226 100644 --- a/.fernignore +++ b/.fernignore @@ -11,3 +11,5 @@ src/main/java/com/merge/legacy # added to QueryStringMapper.java. Once that is fixed, we can remove this file from # .fernignore. src/main/java/com/merge/api/core/QueryStringMapper.java + +src/test/java/com/merge/api/integration/CursorPaginationIntegrationTest.java diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2cba5f8f8..2eaa255f6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,6 +36,10 @@ jobs: - name: Test run: ./gradlew test + env: + MERGE_API_KEY_FILESTORAGE: ${{ secrets.MERGE_API_KEY_FILESTORAGE }} + MERGE_ACCOUNT_TOKEN_FILESTORAGE: ${{ secrets.MERGE_ACCOUNT_TOKEN_FILESTORAGE }} + publish: needs: [ compile, test ] if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') diff --git a/.mock/definition/ATS/accountDetails.yml b/.mock/definition/ATS/accountDetails.yml index ceedb3735..48428454c 100644 --- a/.mock/definition/ATS/accountDetails.yml +++ b/.mock/definition/ATS/accountDetails.yml @@ -7,7 +7,8 @@ service: retrieve: path: /ats/v1/account-details method: GET - auth: true + auth: + - tokenAuth: [] docs: Get details for a linked account. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/accountToken.yml b/.mock/definition/ATS/accountToken.yml index f173e1e9c..ae8d93094 100644 --- a/.mock/definition/ATS/accountToken.yml +++ b/.mock/definition/ATS/accountToken.yml @@ -7,7 +7,8 @@ service: retrieve: path: /ats/v1/account-token/{public_token} method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns the account token for the end user with the provided public token. diff --git a/.mock/definition/ATS/activities.yml b/.mock/definition/ATS/activities.yml index 82396961c..99b916b4c 100644 --- a/.mock/definition/ATS/activities.yml +++ b/.mock/definition/ATS/activities.yml @@ -40,7 +40,8 @@ service: list: path: /ats/v1/activities method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Activity` objects. pagination: cursor: $request.cursor @@ -121,7 +122,19 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: activity_type + remote_id: remote_id + show_enum_origins: activity_type + user_id: user_id headers: X-Account-Token: X-Account-Token response: @@ -153,7 +166,8 @@ service: create: path: /ats/v1/activities method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Activity` object with the given values. source: openapi: ats_v3.yml @@ -178,7 +192,10 @@ service: type: atsRoot.ActivityResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -230,7 +247,8 @@ service: retrieve: path: /ats/v1/activities/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Activity` object with the given `id`. source: openapi: ats_v3.yml @@ -272,6 +290,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: activity_type + show_enum_origins: activity_type headers: X-Account-Token: X-Account-Token response: @@ -300,7 +323,8 @@ service: metaPostRetrieve: path: /ats/v1/activities/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Activity` POSTs. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/applications.yml b/.mock/definition/ATS/applications.yml index 9ebfaa389..c0347b5d3 100644 --- a/.mock/definition/ATS/applications.yml +++ b/.mock/definition/ATS/applications.yml @@ -34,7 +34,8 @@ service: list: path: /ats/v1/applications method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Application` objects. pagination: cursor: $request.cursor @@ -124,7 +125,22 @@ service: status-code: 200 examples: - query-parameters: + candidate_id: candidate_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' + credited_to_id: credited_to_id + current_stage_id: current_stage_id cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + job_id: job_id + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + reject_reason_id: reject_reason_id + remote_id: remote_id + source: source headers: X-Account-Token: X-Account-Token response: @@ -162,7 +178,8 @@ service: create: path: /ats/v1/applications method: POST - auth: true + auth: + - tokenAuth: [] docs: > Creates an `Application` object with the given values. @@ -198,7 +215,10 @@ service: type: atsRoot.ApplicationResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -256,7 +276,8 @@ service: retrieve: path: /ats/v1/applications/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Application` object with the given `id`. source: openapi: ats_v3.yml @@ -288,6 +309,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -322,7 +346,8 @@ service: changeStageCreate: path: /ats/v1/applications/{id}/change-stage method: POST - auth: true + auth: + - tokenAuth: [] docs: Updates the `current_stage` field of an `Application` object source: openapi: ats_v3.yml @@ -358,6 +383,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: {} @@ -414,7 +442,8 @@ service: metaPostRetrieve: path: /ats/v1/applications/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Application` POSTs. source: openapi: ats_v3.yml @@ -431,7 +460,9 @@ service: type: atsRoot.MetaResponse status-code: 200 examples: - - headers: + - query-parameters: + application_remote_template_id: application_remote_template_id + headers: X-Account-Token: X-Account-Token response: body: diff --git a/.mock/definition/ATS/asyncPassthrough.yml b/.mock/definition/ATS/asyncPassthrough.yml index 223951204..b84e9da2a 100644 --- a/.mock/definition/ATS/asyncPassthrough.yml +++ b/.mock/definition/ATS/asyncPassthrough.yml @@ -7,7 +7,8 @@ service: create: path: /ats/v1/async-passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Asynchronously pull data from an endpoint not currently supported by Merge. @@ -32,7 +33,8 @@ service: retrieve: path: /ats/v1/async-passthrough/{async_passthrough_receipt_id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Retrieves data from earlier async-passthrough POST request source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/attachments.yml b/.mock/definition/ATS/attachments.yml index 7e31b4e2f..61e0a1e1e 100644 --- a/.mock/definition/ATS/attachments.yml +++ b/.mock/definition/ATS/attachments.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/attachments method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Attachment` objects. pagination: cursor: $request.cursor @@ -88,7 +89,19 @@ service: status-code: 200 examples: - query-parameters: + candidate_id: candidate_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: attachment_type + remote_id: remote_id + show_enum_origins: attachment_type headers: X-Account-Token: X-Account-Token response: @@ -117,7 +130,8 @@ service: create: path: /ats/v1/attachments method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Attachment` object with the given values. source: openapi: ats_v3.yml @@ -142,7 +156,10 @@ service: type: atsRoot.AttachmentResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -191,7 +208,8 @@ service: retrieve: path: /ats/v1/attachments/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Attachment` object with the given `id`. source: openapi: ats_v3.yml @@ -233,6 +251,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: attachment_type + show_enum_origins: attachment_type headers: X-Account-Token: X-Account-Token response: @@ -258,7 +281,8 @@ service: metaPostRetrieve: path: /ats/v1/attachments/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Attachment` POSTs. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/auditTrail.yml b/.mock/definition/ATS/auditTrail.yml index ee24dbe0e..3a53d381f 100644 --- a/.mock/definition/ATS/auditTrail.yml +++ b/.mock/definition/ATS/auditTrail.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/audit-trail method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets a list of audit trail events. pagination: cursor: $request.cursor @@ -81,6 +82,11 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + event_type: event_type + page_size: 1 + start_date: start_date + user_email: user_email headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/ATS/availableActions.yml b/.mock/definition/ATS/availableActions.yml index 52b67a04c..7cc26f4d9 100644 --- a/.mock/definition/ATS/availableActions.yml +++ b/.mock/definition/ATS/availableActions.yml @@ -7,7 +7,8 @@ service: retrieve: path: /ats/v1/available-actions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of models and actions available for an account. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/candidates.yml b/.mock/definition/ATS/candidates.yml index bfdff22c3..a757ff051 100644 --- a/.mock/definition/ATS/candidates.yml +++ b/.mock/definition/ATS/candidates.yml @@ -20,7 +20,8 @@ service: list: path: /ats/v1/candidates method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Candidate` objects. pagination: cursor: $request.cursor @@ -104,7 +105,20 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + email_addresses: email_addresses + first_name: first_name + include_deleted_data: true + include_remote_data: true + include_shell_data: true + last_name: last_name + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + tags: tags headers: X-Account-Token: X-Account-Token response: @@ -165,7 +179,8 @@ service: create: path: /ats/v1/candidates method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Candidate` object with the given values. source: openapi: ats_v3.yml @@ -190,7 +205,10 @@ service: type: atsRoot.CandidateResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -271,7 +289,8 @@ service: retrieve: path: /ats/v1/candidates/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Candidate` object with the given `id`. source: openapi: ats_v3.yml @@ -303,6 +322,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -363,7 +385,8 @@ service: partialUpdate: path: /ats/v1/candidates/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates a `Candidate` object with the given `id`. source: openapi: ats_v3.yml @@ -392,6 +415,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -473,7 +499,8 @@ service: ignoreCreate: path: /ats/v1/candidates/ignore/{model_id} method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in @@ -496,7 +523,8 @@ service: metaPatchRetrieve: path: /ats/v1/candidates/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Candidate` PATCHs. source: openapi: ats_v3.yml @@ -685,7 +713,8 @@ service: metaPostRetrieve: path: /ats/v1/candidates/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Candidate` POSTs. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/deleteAccount.yml b/.mock/definition/ATS/deleteAccount.yml index 57554adc1..b902b54e2 100644 --- a/.mock/definition/ATS/deleteAccount.yml +++ b/.mock/definition/ATS/deleteAccount.yml @@ -5,7 +5,8 @@ service: delete: path: /ats/v1/delete-account method: POST - auth: true + auth: + - tokenAuth: [] docs: Delete a linked account. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/departments.yml b/.mock/definition/ATS/departments.yml index d93c61334..d8eee7ec7 100644 --- a/.mock/definition/ATS/departments.yml +++ b/.mock/definition/ATS/departments.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/departments method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Department` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -95,7 +105,8 @@ service: retrieve: path: /ats/v1/departments/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Department` object with the given `id`. source: openapi: ats_v3.yml @@ -121,6 +132,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/eeocs.yml b/.mock/definition/ATS/eeocs.yml index 0db75d4d3..a5b85dc56 100644 --- a/.mock/definition/ATS/eeocs.yml +++ b/.mock/definition/ATS/eeocs.yml @@ -128,7 +128,8 @@ service: list: path: /ats/v1/eeocs method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `EEOC` objects. pagination: cursor: $request.cursor @@ -209,7 +210,19 @@ service: status-code: 200 examples: - query-parameters: + candidate_id: candidate_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: disability_status + remote_id: remote_id + show_enum_origins: disability_status headers: X-Account-Token: X-Account-Token response: @@ -240,7 +253,8 @@ service: retrieve: path: /ats/v1/eeocs/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `EEOC` object with the given `id`. source: openapi: ats_v3.yml @@ -282,6 +296,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: disability_status + show_enum_origins: disability_status headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/fieldMapping.yml b/.mock/definition/ATS/fieldMapping.yml index 4a80e0158..bda9917a7 100644 --- a/.mock/definition/ATS/fieldMapping.yml +++ b/.mock/definition/ATS/fieldMapping.yml @@ -7,7 +7,8 @@ service: field_mappings_retrieve: path: /ats/v1/field-mappings method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge @@ -30,7 +31,9 @@ service: type: atsRoot.FieldMappingApiInstanceResponse status-code: 200 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token response: body: @@ -293,7 +296,8 @@ service: field_mappings_create: path: /ats/v1/field-mappings method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to @@ -358,7 +362,9 @@ service: type: atsRoot.FieldMappingInstanceResponse status-code: 201 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token request: target_field_name: example_target_field_name @@ -409,7 +415,8 @@ service: field_mappings_destroy: path: /ats/v1/field-mappings/{field_mapping_id} method: DELETE - auth: true + auth: + - tokenAuth: [] docs: >- Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after @@ -469,7 +476,8 @@ service: field_mappings_partial_update: path: /ats/v1/field-mappings/{field_mapping_id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: >- Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the @@ -553,7 +561,8 @@ service: remote_fields_retrieve: path: /ats/v1/remote-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data @@ -581,7 +590,10 @@ service: type: atsRoot.RemoteFieldApiResponse status-code: 200 examples: - - headers: + - query-parameters: + common_models: common_models + include_example_values: include_example_values + headers: X-Account-Token: X-Account-Token response: body: @@ -812,7 +824,8 @@ service: target_fields_retrieve: path: /ats/v1/target-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields diff --git a/.mock/definition/ATS/forceResync.yml b/.mock/definition/ATS/forceResync.yml index 83e61cfe7..c19f53b4d 100644 --- a/.mock/definition/ATS/forceResync.yml +++ b/.mock/definition/ATS/forceResync.yml @@ -7,7 +7,8 @@ service: sync_status_resync_create: path: /ats/v1/sync-status/resync method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or diff --git a/.mock/definition/ATS/generateKey.yml b/.mock/definition/ATS/generateKey.yml index 81499ceaa..b9f011f38 100644 --- a/.mock/definition/ATS/generateKey.yml +++ b/.mock/definition/ATS/generateKey.yml @@ -7,7 +7,8 @@ service: create: path: /ats/v1/generate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Create a remote key. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/interviews.yml b/.mock/definition/ATS/interviews.yml index ebd796d68..9fb16f5dd 100644 --- a/.mock/definition/ATS/interviews.yml +++ b/.mock/definition/ATS/interviews.yml @@ -24,7 +24,8 @@ service: list: path: /ats/v1/interviews method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `ScheduledInterview` objects. pagination: cursor: $request.cursor @@ -114,7 +115,22 @@ service: status-code: 200 examples: - query-parameters: + application_id: application_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + job_id: job_id + job_interview_stage_id: job_interview_stage_id + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + organizer_id: organizer_id + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -151,7 +167,8 @@ service: create: path: /ats/v1/interviews method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `ScheduledInterview` object with the given values. source: openapi: ats_v3.yml @@ -176,7 +193,10 @@ service: type: atsRoot.ScheduledInterviewResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -233,7 +253,8 @@ service: retrieve: path: /ats/v1/interviews/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `ScheduledInterview` object with the given `id`. source: openapi: ats_v3.yml @@ -275,6 +296,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -308,7 +334,8 @@ service: metaPostRetrieve: path: /ats/v1/interviews/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `ScheduledInterview` POSTs. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/issues.yml b/.mock/definition/ATS/issues.yml index 143fae061..b446519fc 100644 --- a/.mock/definition/ATS/issues.yml +++ b/.mock/definition/ATS/issues.yml @@ -14,7 +14,8 @@ service: list: path: /ats/v1/issues method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets all issues for Organization. pagination: cursor: $request.cursor @@ -85,7 +86,20 @@ service: status-code: 200 examples: - query-parameters: + account_token: account_token cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + end_user_organization_name: end_user_organization_name + first_incident_time_after: '2024-01-15T09:30:00Z' + first_incident_time_before: '2024-01-15T09:30:00Z' + include_muted: include_muted + integration_name: integration_name + last_incident_time_after: '2024-01-15T09:30:00Z' + last_incident_time_before: '2024-01-15T09:30:00Z' + linked_account_id: linked_account_id + page_size: 1 + start_date: start_date + status: ONGOING headers: X-Account-Token: '[object Object]' response: @@ -107,7 +121,8 @@ service: retrieve: path: /ats/v1/issues/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Get a specific issue. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/jobInterviewStages.yml b/.mock/definition/ATS/jobInterviewStages.yml index 121dd26da..413ae6f94 100644 --- a/.mock/definition/ATS/jobInterviewStages.yml +++ b/.mock/definition/ATS/jobInterviewStages.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/job-interview-stages method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `JobInterviewStage` objects. pagination: cursor: $request.cursor @@ -78,7 +79,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + job_id: job_id + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -106,7 +117,8 @@ service: retrieve: path: /ats/v1/job-interview-stages/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `JobInterviewStage` object with the given `id`. source: openapi: ats_v3.yml @@ -138,6 +150,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/jobPostings.yml b/.mock/definition/ATS/jobPostings.yml index 5dfc648cd..3863a2d7b 100644 --- a/.mock/definition/ATS/jobPostings.yml +++ b/.mock/definition/ATS/jobPostings.yml @@ -17,7 +17,8 @@ service: list: path: /ats/v1/job-postings method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `JobPosting` objects. pagination: cursor: $request.cursor @@ -101,7 +102,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + status: CLOSED headers: X-Account-Token: X-Account-Token response: @@ -138,7 +149,8 @@ service: retrieve: path: /ats/v1/job-postings/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `JobPosting` object with the given `id`. source: openapi: ats_v3.yml @@ -170,6 +182,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/jobs.yml b/.mock/definition/ATS/jobs.yml index 503b1d472..3c8d1a781 100644 --- a/.mock/definition/ATS/jobs.yml +++ b/.mock/definition/ATS/jobs.yml @@ -41,7 +41,8 @@ service: list: path: /ats/v1/jobs method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Job` objects. pagination: cursor: $request.cursor @@ -143,7 +144,21 @@ service: status-code: 200 examples: - query-parameters: + code: code + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + offices: offices + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status + status: ARCHIVED headers: X-Account-Token: X-Account-Token response: @@ -195,7 +210,8 @@ service: retrieve: path: /ats/v1/jobs/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Job` object with the given `id`. source: openapi: ats_v3.yml @@ -237,6 +253,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -286,7 +307,8 @@ service: screeningQuestionsList: path: /ats/v1/jobs/{job_id}/screening-questions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `ScreeningQuestion` objects. pagination: cursor: $request.cursor @@ -338,6 +360,10 @@ service: job_id: job_id query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/linkToken.yml b/.mock/definition/ATS/linkToken.yml index 12e0eb21d..df4d0a840 100644 --- a/.mock/definition/ATS/linkToken.yml +++ b/.mock/definition/ATS/linkToken.yml @@ -24,7 +24,8 @@ service: create: path: /ats/v1/link-token method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a link token to be used when linking a new end user. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/linkedAccounts.yml b/.mock/definition/ATS/linkedAccounts.yml index 1b0bc5b3b..fec205e74 100644 --- a/.mock/definition/ATS/linkedAccounts.yml +++ b/.mock/definition/ATS/linkedAccounts.yml @@ -19,7 +19,8 @@ service: list: path: /ats/v1/linked-accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: List linked accounts for your organization. pagination: cursor: $request.cursor @@ -112,7 +113,19 @@ service: status-code: 200 examples: - query-parameters: + category: accounting cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_user_email_address: end_user_email_address + end_user_organization_name: end_user_organization_name + end_user_origin_id: end_user_origin_id + end_user_origin_ids: end_user_origin_ids + id: id + ids: ids + include_duplicates: true + integration_name: integration_name + is_test_account: is_test_account + page_size: 1 + status: status headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/ATS/offers.yml b/.mock/definition/ATS/offers.yml index 5e12683c1..37733768f 100644 --- a/.mock/definition/ATS/offers.yml +++ b/.mock/definition/ATS/offers.yml @@ -20,7 +20,8 @@ service: list: path: /ats/v1/offers method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Offer` objects. pagination: cursor: $request.cursor @@ -104,7 +105,20 @@ service: status-code: 200 examples: - query-parameters: + application_id: application_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' + creator_id: creator_id cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -136,7 +150,8 @@ service: retrieve: path: /ats/v1/offers/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Offer` object with the given `id`. source: openapi: ats_v3.yml @@ -178,6 +193,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/offices.yml b/.mock/definition/ATS/offices.yml index b38aec464..9d144f262 100644 --- a/.mock/definition/ATS/offices.yml +++ b/.mock/definition/ATS/offices.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/offices method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Office` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -96,7 +106,8 @@ service: retrieve: path: /ats/v1/offices/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Office` object with the given `id`. source: openapi: ats_v3.yml @@ -122,6 +133,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/passthrough.yml b/.mock/definition/ATS/passthrough.yml index d66e65d8e..52615aad9 100644 --- a/.mock/definition/ATS/passthrough.yml +++ b/.mock/definition/ATS/passthrough.yml @@ -7,7 +7,8 @@ service: create: path: /ats/v1/passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: Pull data from an endpoint not currently supported by Merge. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/regenerateKey.yml b/.mock/definition/ATS/regenerateKey.yml index 0ba6ec09b..08d64644e 100644 --- a/.mock/definition/ATS/regenerateKey.yml +++ b/.mock/definition/ATS/regenerateKey.yml @@ -7,7 +7,8 @@ service: create: path: /ats/v1/regenerate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Exchange remote keys. source: openapi: ats_v3.yml diff --git a/.mock/definition/ATS/rejectReasons.yml b/.mock/definition/ATS/rejectReasons.yml index 630b175ef..563303a42 100644 --- a/.mock/definition/ATS/rejectReasons.yml +++ b/.mock/definition/ATS/rejectReasons.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/reject-reasons method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RejectReason` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -95,7 +105,8 @@ service: retrieve: path: /ats/v1/reject-reasons/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `RejectReason` object with the given `id`. source: openapi: ats_v3.yml @@ -121,6 +132,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/scopes.yml b/.mock/definition/ATS/scopes.yml index 82ca890c9..9fc4d12f8 100644 --- a/.mock/definition/ATS/scopes.yml +++ b/.mock/definition/ATS/scopes.yml @@ -7,7 +7,8 @@ service: default_scopes_retrieve: path: /ats/v1/default-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn @@ -50,7 +51,8 @@ service: linked_account_scopes_retrieve: path: /ats/v1/linked-account-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn @@ -93,7 +95,8 @@ service: linked_account_scopes_create: path: /ats/v1/linked-account-scopes method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the diff --git a/.mock/definition/ATS/scorecards.yml b/.mock/definition/ATS/scorecards.yml index aee7af170..5856ace67 100644 --- a/.mock/definition/ATS/scorecards.yml +++ b/.mock/definition/ATS/scorecards.yml @@ -22,7 +22,8 @@ service: list: path: /ats/v1/scorecards method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Scorecard` objects. pagination: cursor: $request.cursor @@ -109,7 +110,21 @@ service: status-code: 200 examples: - query-parameters: + application_id: application_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + interview_id: interview_id + interviewer_id: interviewer_id + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: overall_recommendation + remote_id: remote_id + show_enum_origins: overall_recommendation headers: X-Account-Token: X-Account-Token response: @@ -140,7 +155,8 @@ service: retrieve: path: /ats/v1/scorecards/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Scorecard` object with the given `id`. source: openapi: ats_v3.yml @@ -182,6 +198,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: overall_recommendation + show_enum_origins: overall_recommendation headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/syncStatus.yml b/.mock/definition/ATS/syncStatus.yml index 456784e72..6430f8d03 100644 --- a/.mock/definition/ATS/syncStatus.yml +++ b/.mock/definition/ATS/syncStatus.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/sync-status method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. @@ -42,6 +43,7 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/tags.yml b/.mock/definition/ATS/tags.yml index f04050e5b..33e751f61 100644 --- a/.mock/definition/ATS/tags.yml +++ b/.mock/definition/ATS/tags.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/tags method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Tag` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/users.yml b/.mock/definition/ATS/users.yml index 72f9d923d..13abe7c91 100644 --- a/.mock/definition/ATS/users.yml +++ b/.mock/definition/ATS/users.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/users method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteUser` objects. pagination: cursor: $request.cursor @@ -86,7 +87,19 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + email: email + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: access_role + remote_id: remote_id + show_enum_origins: access_role headers: X-Account-Token: X-Account-Token response: @@ -117,7 +130,8 @@ service: retrieve: path: /ats/v1/users/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `RemoteUser` object with the given `id`. source: openapi: ats_v3.yml @@ -153,6 +167,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: access_role + show_enum_origins: access_role headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/ATS/webhookReceivers.yml b/.mock/definition/ATS/webhookReceivers.yml index 79f6c401a..b65ab6cc9 100644 --- a/.mock/definition/ATS/webhookReceivers.yml +++ b/.mock/definition/ATS/webhookReceivers.yml @@ -7,7 +7,8 @@ service: list: path: /ats/v1/webhook-receivers method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `WebhookReceiver` objects. source: openapi: ats_v3.yml @@ -26,7 +27,8 @@ service: create: path: /ats/v1/webhook-receivers method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `WebhookReceiver` object with the given values. source: openapi: ats_v3.yml diff --git a/.mock/definition/Accounting/accountDetails.yml b/.mock/definition/Accounting/accountDetails.yml index 5bdbb0610..865ea0552 100644 --- a/.mock/definition/Accounting/accountDetails.yml +++ b/.mock/definition/Accounting/accountDetails.yml @@ -7,7 +7,8 @@ service: retrieve: path: /accounting/v1/account-details method: GET - auth: true + auth: + - tokenAuth: [] docs: Get details for a linked account. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/accountToken.yml b/.mock/definition/Accounting/accountToken.yml index 61cb17d8e..5218fcc77 100644 --- a/.mock/definition/Accounting/accountToken.yml +++ b/.mock/definition/Accounting/accountToken.yml @@ -7,7 +7,8 @@ service: retrieve: path: /accounting/v1/account-token/{public_token} method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns the account token for the end user with the provided public token. diff --git a/.mock/definition/Accounting/accountingPeriods.yml b/.mock/definition/Accounting/accountingPeriods.yml index d06c13190..871b63667 100644 --- a/.mock/definition/Accounting/accountingPeriods.yml +++ b/.mock/definition/Accounting/accountingPeriods.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/accounting-periods method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `AccountingPeriod` objects. pagination: cursor: $request.cursor @@ -49,6 +50,10 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -76,7 +81,8 @@ service: retrieve: path: /accounting/v1/accounting-periods/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `AccountingPeriod` object with the given `id`. source: openapi: accounting_v3.yml @@ -102,6 +108,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/accounts.yml b/.mock/definition/Accounting/accounts.yml index 83dd930e6..f1fb20b8b 100644 --- a/.mock/definition/Accounting/accounts.yml +++ b/.mock/definition/Accounting/accounts.yml @@ -1,4 +1,15 @@ types: + AccountsListRequestClassification: + enum: + - value: '' + name: EMPTY + - ASSET + - EQUITY + - EXPENSE + - LIABILITY + - REVENUE + source: + openapi: accounting_v3.yml AccountsListRequestRemoteFields: enum: - classification @@ -15,6 +26,15 @@ types: - status source: openapi: accounting_v3.yml + AccountsListRequestStatus: + enum: + - value: '' + name: EMPTY + - ACTIVE + - INACTIVE + - PENDING + source: + openapi: accounting_v3.yml AccountsRetrieveRequestRemoteFields: enum: - classification @@ -40,7 +60,8 @@ service: list: path: /accounting/v1/accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Account` objects. pagination: cursor: $request.cursor @@ -55,7 +76,7 @@ service: type: optional docs: If provided, will only return accounts with the passed in enum. classification: - type: optional + type: optional docs: If provided, will only return accounts with this classification. company_id: type: optional @@ -125,7 +146,7 @@ service: enum values. [Learn more](https://help.merge.dev/en/articles/8950958-show_enum_origins-query-parameter) status: - type: optional + type: optional docs: If provided, will only return accounts with this status. response: docs: '' @@ -133,7 +154,23 @@ service: status-code: 200 examples: - query-parameters: + account_type: account_type + classification: '' + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + page_size: 1 + remote_fields: classification + remote_id: remote_id + show_enum_origins: classification + status: '' headers: X-Account-Token: X-Account-Token response: @@ -169,7 +206,8 @@ service: create: path: /accounting/v1/accounts method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Account` object with the given values. source: openapi: accounting_v3.yml @@ -193,7 +231,10 @@ service: type: accountingRoot.AccountResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -248,7 +289,8 @@ service: retrieve: path: /accounting/v1/accounts/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Account` object with the given `id`. source: openapi: accounting_v3.yml @@ -290,6 +332,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: classification + show_enum_origins: classification headers: X-Account-Token: X-Account-Token response: @@ -322,7 +369,8 @@ service: metaPostRetrieve: path: /accounting/v1/accounts/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Account` POSTs. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/addresses.yml b/.mock/definition/Accounting/addresses.yml index e8d9f6661..c7dc06e93 100644 --- a/.mock/definition/Accounting/addresses.yml +++ b/.mock/definition/Accounting/addresses.yml @@ -7,7 +7,8 @@ service: retrieve: path: /accounting/v1/addresses/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Address` object with the given `id`. source: openapi: accounting_v3.yml @@ -43,6 +44,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: type + show_enum_origins: type headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/asyncPassthrough.yml b/.mock/definition/Accounting/asyncPassthrough.yml index 8265047e6..72b58442c 100644 --- a/.mock/definition/Accounting/asyncPassthrough.yml +++ b/.mock/definition/Accounting/asyncPassthrough.yml @@ -7,7 +7,8 @@ service: create: path: /accounting/v1/async-passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Asynchronously pull data from an endpoint not currently supported by Merge. @@ -32,7 +33,8 @@ service: retrieve: path: /accounting/v1/async-passthrough/{async_passthrough_receipt_id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Retrieves data from earlier async-passthrough POST request source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/asyncTasks.yml b/.mock/definition/Accounting/asyncTasks.yml index 603a4e6b8..f4ca6af13 100644 --- a/.mock/definition/Accounting/asyncTasks.yml +++ b/.mock/definition/Accounting/asyncTasks.yml @@ -7,7 +7,8 @@ service: retrieve: path: /accounting/v1/async-tasks/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `AsyncPostTask` object with the given `id`. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/attachments.yml b/.mock/definition/Accounting/attachments.yml index a1b2e6c21..fd49f37f5 100644 --- a/.mock/definition/Accounting/attachments.yml +++ b/.mock/definition/Accounting/attachments.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/attachments method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `AccountingAttachment` objects. pagination: cursor: $request.cursor @@ -74,7 +75,17 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -103,7 +114,8 @@ service: create: path: /accounting/v1/attachments method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `AccountingAttachment` object with the given values. source: openapi: accounting_v3.yml @@ -127,7 +139,10 @@ service: type: accountingRoot.AccountingAttachmentResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -175,7 +190,8 @@ service: retrieve: path: /accounting/v1/attachments/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `AccountingAttachment` object with the given `id`. source: openapi: accounting_v3.yml @@ -201,6 +217,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -226,7 +245,8 @@ service: metaPostRetrieve: path: /accounting/v1/attachments/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `AccountingAttachment` POSTs. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/auditTrail.yml b/.mock/definition/Accounting/auditTrail.yml index 39627b8ae..f8feeb9b3 100644 --- a/.mock/definition/Accounting/auditTrail.yml +++ b/.mock/definition/Accounting/auditTrail.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/audit-trail method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets a list of audit trail events. pagination: cursor: $request.cursor @@ -81,6 +82,11 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + event_type: event_type + page_size: 1 + start_date: start_date + user_email: user_email headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/Accounting/availableActions.yml b/.mock/definition/Accounting/availableActions.yml index bb66c38c2..8a30ab4bd 100644 --- a/.mock/definition/Accounting/availableActions.yml +++ b/.mock/definition/Accounting/availableActions.yml @@ -7,7 +7,8 @@ service: retrieve: path: /accounting/v1/available-actions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of models and actions available for an account. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/balanceSheets.yml b/.mock/definition/Accounting/balanceSheets.yml index 0cb28db95..7f0352bc4 100644 --- a/.mock/definition/Accounting/balanceSheets.yml +++ b/.mock/definition/Accounting/balanceSheets.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/balance-sheets method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `BalanceSheet` objects. pagination: cursor: $request.cursor @@ -78,7 +79,17 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -146,7 +157,8 @@ service: retrieve: path: /accounting/v1/balance-sheets/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `BalanceSheet` object with the given `id`. source: openapi: accounting_v3.yml @@ -178,6 +190,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/bankFeedAccounts.yml b/.mock/definition/Accounting/bankFeedAccounts.yml index f930bdc5f..edf14a7a9 100644 --- a/.mock/definition/Accounting/bankFeedAccounts.yml +++ b/.mock/definition/Accounting/bankFeedAccounts.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/bank-feed-accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `BankFeedAccount` objects. pagination: cursor: $request.cursor @@ -49,6 +50,10 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -76,10 +81,13 @@ service: custom_key: custom_value linked_account_defined_targets: custom_key: custom_value + remote_data: + - null create: path: /accounting/v1/bank-feed-accounts method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `BankFeedAccount` object with the given values. source: openapi: accounting_v3.yml @@ -103,7 +111,10 @@ service: type: accountingRoot.BankFeedAccountResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -155,7 +166,8 @@ service: retrieve: path: /accounting/v1/bank-feed-accounts/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `BankFeedAccount` object with the given `id`. source: openapi: accounting_v3.yml @@ -181,6 +193,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -210,7 +225,8 @@ service: metaPostRetrieve: path: /accounting/v1/bank-feed-accounts/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `BankFeedAccount` POSTs. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/bankFeedTransactions.yml b/.mock/definition/Accounting/bankFeedTransactions.yml index 9454bcf21..8a23cacb8 100644 --- a/.mock/definition/Accounting/bankFeedTransactions.yml +++ b/.mock/definition/Accounting/bankFeedTransactions.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/bank-feed-transactions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `BankFeedTransaction` objects. pagination: cursor: $request.cursor @@ -80,7 +81,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_processed: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -106,7 +117,8 @@ service: create: path: /accounting/v1/bank-feed-transactions method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `BankFeedTransaction` object with the given values. source: openapi: accounting_v3.yml @@ -130,7 +142,10 @@ service: type: accountingRoot.BankFeedTransactionResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -175,7 +190,8 @@ service: retrieve: path: /accounting/v1/bank-feed-transactions/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `BankFeedTransaction` object with the given `id`. source: openapi: accounting_v3.yml @@ -207,6 +223,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -229,7 +248,8 @@ service: metaPostRetrieve: path: /accounting/v1/bank-feed-transactions/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `BankFeedTransaction` POSTs. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/cashFlowStatements.yml b/.mock/definition/Accounting/cashFlowStatements.yml index 78e66c7b0..52afdc7ac 100644 --- a/.mock/definition/Accounting/cashFlowStatements.yml +++ b/.mock/definition/Accounting/cashFlowStatements.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/cash-flow-statements method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `CashFlowStatement` objects. pagination: cursor: $request.cursor @@ -80,7 +81,17 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -147,7 +158,8 @@ service: retrieve: path: /accounting/v1/cash-flow-statements/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `CashFlowStatement` object with the given `id`. source: openapi: accounting_v3.yml @@ -179,6 +191,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/companyInfo.yml b/.mock/definition/Accounting/companyInfo.yml index dccfc4379..76a4eaf10 100644 --- a/.mock/definition/Accounting/companyInfo.yml +++ b/.mock/definition/Accounting/companyInfo.yml @@ -20,7 +20,8 @@ service: list: path: /accounting/v1/company-info method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `CompanyInfo` objects. pagination: cursor: $request.cursor @@ -88,7 +89,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -108,6 +118,8 @@ service: currency: key: value remote_created_at: '2020-03-31T00:00:00Z' + urls: + - null addresses: - created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' @@ -133,7 +145,8 @@ service: retrieve: path: /accounting/v1/company-info/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `CompanyInfo` object with the given `id`. source: openapi: accounting_v3.yml @@ -165,6 +178,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/contacts.yml b/.mock/definition/Accounting/contacts.yml index 8e4df145a..dfa18135d 100644 --- a/.mock/definition/Accounting/contacts.yml +++ b/.mock/definition/Accounting/contacts.yml @@ -6,6 +6,14 @@ types: - phone_numbers source: openapi: accounting_v3.yml + ContactsListRequestStatus: + enum: + - value: '' + name: EMPTY + - ACTIVE + - ARCHIVED + source: + openapi: accounting_v3.yml ContactsRetrieveRequestExpandItem: enum: - addresses @@ -22,7 +30,8 @@ service: list: path: /accounting/v1/contacts method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Contact` objects. pagination: cursor: $request.cursor @@ -119,7 +128,7 @@ service: enum values. [Learn more](https://help.merge.dev/en/articles/8950958-show_enum_origins-query-parameter) status: - type: optional + type: optional docs: If provided, will only return Contacts that match this status. response: docs: '' @@ -127,7 +136,25 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + email_address: email_address + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_customer: is_customer + is_supplier: is_supplier + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status + status: '' headers: X-Account-Token: X-Account-Token response: @@ -171,7 +198,8 @@ service: create: path: /accounting/v1/contacts method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Contact` object with the given values. source: openapi: accounting_v3.yml @@ -195,7 +223,10 @@ service: type: accountingRoot.ContactResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -258,7 +289,8 @@ service: retrieve: path: /accounting/v1/contacts/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Contact` object with the given `id`. source: openapi: accounting_v3.yml @@ -305,6 +337,12 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -347,7 +385,8 @@ service: metaPostRetrieve: path: /accounting/v1/contacts/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Contact` POSTs. source: openapi: accounting_v3.yml @@ -532,7 +571,8 @@ service: remoteFieldClassesList: path: /accounting/v1/contacts/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -584,6 +624,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/creditNotes.yml b/.mock/definition/Accounting/creditNotes.yml index e8c400eae..db88f86f6 100644 --- a/.mock/definition/Accounting/creditNotes.yml +++ b/.mock/definition/Accounting/creditNotes.yml @@ -62,7 +62,8 @@ service: list: path: /accounting/v1/credit-notes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `CreditNote` objects. pagination: cursor: $request.cursor @@ -151,7 +152,21 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status + transaction_date_after: '2024-01-15T09:30:00Z' + transaction_date_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -225,7 +240,8 @@ service: create: path: /accounting/v1/credit-notes method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `CreditNote` object with the given values. source: openapi: accounting_v3.yml @@ -249,7 +265,10 @@ service: type: accountingRoot.CreditNoteResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -342,7 +361,8 @@ service: retrieve: path: /accounting/v1/credit-notes/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `CreditNote` object with the given `id`. source: openapi: accounting_v3.yml @@ -384,6 +404,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -456,7 +481,8 @@ service: metaPostRetrieve: path: /accounting/v1/credit-notes/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `CreditNote` POSTs. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/deleteAccount.yml b/.mock/definition/Accounting/deleteAccount.yml index b24eb1c18..ac30455d0 100644 --- a/.mock/definition/Accounting/deleteAccount.yml +++ b/.mock/definition/Accounting/deleteAccount.yml @@ -5,7 +5,8 @@ service: delete: path: /accounting/v1/delete-account method: POST - auth: true + auth: + - tokenAuth: [] docs: Delete a linked account. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/employees.yml b/.mock/definition/Accounting/employees.yml index dd9d14284..15a0cdb68 100644 --- a/.mock/definition/Accounting/employees.yml +++ b/.mock/definition/Accounting/employees.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/employees method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Employee` objects. pagination: cursor: $request.cursor @@ -55,6 +56,10 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -86,7 +91,8 @@ service: retrieve: path: /accounting/v1/employees/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Employee` object with the given `id`. source: openapi: accounting_v3.yml @@ -118,6 +124,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/expenses.yml b/.mock/definition/Accounting/expenses.yml index 340dcba16..c039baab8 100644 --- a/.mock/definition/Accounting/expenses.yml +++ b/.mock/definition/Accounting/expenses.yml @@ -28,7 +28,8 @@ service: list: path: /accounting/v1/expenses method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Expense` objects. pagination: cursor: $request.cursor @@ -112,7 +113,20 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + transaction_date_after: '2024-01-15T09:30:00Z' + transaction_date_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -189,7 +203,8 @@ service: create: path: /accounting/v1/expenses method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Expense` object with the given values. source: openapi: accounting_v3.yml @@ -213,7 +228,10 @@ service: type: accountingRoot.ExpenseResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -309,7 +327,8 @@ service: retrieve: path: /accounting/v1/expenses/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Expense` object with the given `id`. source: openapi: accounting_v3.yml @@ -346,6 +365,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -430,7 +453,8 @@ service: linesRemoteFieldClassesList: path: /accounting/v1/expenses/lines/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -482,6 +506,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -502,7 +532,8 @@ service: metaPostRetrieve: path: /accounting/v1/expenses/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Expense` POSTs. source: openapi: accounting_v3.yml @@ -687,7 +718,8 @@ service: remoteFieldClassesList: path: /accounting/v1/expenses/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -739,6 +771,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/fieldMapping.yml b/.mock/definition/Accounting/fieldMapping.yml index 6a1dc9c09..e8c557cdb 100644 --- a/.mock/definition/Accounting/fieldMapping.yml +++ b/.mock/definition/Accounting/fieldMapping.yml @@ -7,7 +7,8 @@ service: field_mappings_retrieve: path: /accounting/v1/field-mappings method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge @@ -30,7 +31,9 @@ service: type: accountingRoot.FieldMappingApiInstanceResponse status-code: 200 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token response: body: @@ -437,7 +440,8 @@ service: field_mappings_create: path: /accounting/v1/field-mappings method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to @@ -502,7 +506,9 @@ service: type: accountingRoot.FieldMappingInstanceResponse status-code: 201 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token request: target_field_name: example_target_field_name @@ -553,7 +559,8 @@ service: field_mappings_destroy: path: /accounting/v1/field-mappings/{field_mapping_id} method: DELETE - auth: true + auth: + - tokenAuth: [] docs: >- Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after @@ -613,7 +620,8 @@ service: field_mappings_partial_update: path: /accounting/v1/field-mappings/{field_mapping_id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: >- Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the @@ -697,7 +705,8 @@ service: remote_fields_retrieve: path: /accounting/v1/remote-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data @@ -725,7 +734,10 @@ service: type: accountingRoot.RemoteFieldApiResponse status-code: 200 examples: - - headers: + - query-parameters: + common_models: common_models + include_example_values: include_example_values + headers: X-Account-Token: X-Account-Token response: body: @@ -1082,7 +1094,8 @@ service: target_fields_retrieve: path: /accounting/v1/target-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields diff --git a/.mock/definition/Accounting/forceResync.yml b/.mock/definition/Accounting/forceResync.yml index 273b8d71e..b9631fd75 100644 --- a/.mock/definition/Accounting/forceResync.yml +++ b/.mock/definition/Accounting/forceResync.yml @@ -7,7 +7,8 @@ service: sync_status_resync_create: path: /accounting/v1/sync-status/resync method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or diff --git a/.mock/definition/Accounting/generalLedgerTransactions.yml b/.mock/definition/Accounting/generalLedgerTransactions.yml index 8bdc16a93..12923c804 100644 --- a/.mock/definition/Accounting/generalLedgerTransactions.yml +++ b/.mock/definition/Accounting/generalLedgerTransactions.yml @@ -24,7 +24,8 @@ service: list: path: /accounting/v1/general-ledger-transactions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `GeneralLedgerTransaction` objects. pagination: cursor: $request.cursor @@ -103,7 +104,19 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + posted_date_after: '2024-01-15T09:30:00Z' + posted_date_before: '2024-01-15T09:30:00Z' + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -159,7 +172,8 @@ service: retrieve: path: /accounting/v1/general-ledger-transactions/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `GeneralLedgerTransaction` object with the given `id`. source: openapi: accounting_v3.yml @@ -191,6 +205,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/generateKey.yml b/.mock/definition/Accounting/generateKey.yml index 783b8fbae..ba16ddeac 100644 --- a/.mock/definition/Accounting/generateKey.yml +++ b/.mock/definition/Accounting/generateKey.yml @@ -7,7 +7,8 @@ service: create: path: /accounting/v1/generate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Create a remote key. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/incomeStatements.yml b/.mock/definition/Accounting/incomeStatements.yml index 75278d467..0c2e79b01 100644 --- a/.mock/definition/Accounting/incomeStatements.yml +++ b/.mock/definition/Accounting/incomeStatements.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/income-statements method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `IncomeStatement` objects. pagination: cursor: $request.cursor @@ -78,7 +79,17 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -160,7 +171,8 @@ service: retrieve: path: /accounting/v1/income-statements/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `IncomeStatement` object with the given `id`. source: openapi: accounting_v3.yml @@ -192,6 +204,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/invoices.yml b/.mock/definition/Accounting/invoices.yml index 9cc0026ba..304889f61 100644 --- a/.mock/definition/Accounting/invoices.yml +++ b/.mock/definition/Accounting/invoices.yml @@ -56,7 +56,8 @@ service: list: path: /accounting/v1/invoices method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Invoice` objects. pagination: cursor: $request.cursor @@ -174,7 +175,26 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + contact_id: contact_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + issue_date_after: '2024-01-15T09:30:00Z' + issue_date_before: '2024-01-15T09:30:00Z' + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + number: number + page_size: 1 + remote_fields: type + remote_id: remote_id + show_enum_origins: type + status: DRAFT + type: ACCOUNTS_PAYABLE headers: X-Account-Token: X-Account-Token response: @@ -268,7 +288,8 @@ service: create: path: /accounting/v1/invoices method: POST - auth: true + auth: + - tokenAuth: [] docs: |- Creates an `Invoice` object with the given values. Including a `PurchaseOrder` id in the `purchase_orders` property will generate an Accounts Payable Invoice from the specified Purchase Order(s). @@ -295,7 +316,10 @@ service: type: accountingRoot.InvoiceResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -408,7 +432,8 @@ service: retrieve: path: /accounting/v1/invoices/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Invoice` object with the given `id`. source: openapi: accounting_v3.yml @@ -455,6 +480,12 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true + remote_fields: type + show_enum_origins: type headers: X-Account-Token: X-Account-Token response: @@ -559,7 +590,8 @@ service: partialUpdate: path: /accounting/v1/invoices/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates an `Invoice` object with the given `id`. source: openapi: accounting_v3.yml @@ -587,6 +619,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -700,7 +735,8 @@ service: lineItemsRemoteFieldClassesList: path: /accounting/v1/invoices/line-items/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -752,6 +788,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -772,7 +814,8 @@ service: metaPatchRetrieve: path: /accounting/v1/invoices/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Invoice` PATCHs. source: openapi: accounting_v3.yml @@ -961,7 +1004,8 @@ service: metaPostRetrieve: path: /accounting/v1/invoices/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Invoice` POSTs. source: openapi: accounting_v3.yml @@ -1146,7 +1190,8 @@ service: remoteFieldClassesList: path: /accounting/v1/invoices/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -1198,6 +1243,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/issues.yml b/.mock/definition/Accounting/issues.yml index d5e7e7935..01dadddb0 100644 --- a/.mock/definition/Accounting/issues.yml +++ b/.mock/definition/Accounting/issues.yml @@ -14,7 +14,8 @@ service: list: path: /accounting/v1/issues method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets all issues for Organization. pagination: cursor: $request.cursor @@ -85,7 +86,20 @@ service: status-code: 200 examples: - query-parameters: + account_token: account_token cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + end_user_organization_name: end_user_organization_name + first_incident_time_after: '2024-01-15T09:30:00Z' + first_incident_time_before: '2024-01-15T09:30:00Z' + include_muted: include_muted + integration_name: integration_name + last_incident_time_after: '2024-01-15T09:30:00Z' + last_incident_time_before: '2024-01-15T09:30:00Z' + linked_account_id: linked_account_id + page_size: 1 + start_date: start_date + status: ONGOING headers: X-Account-Token: '[object Object]' response: @@ -107,7 +121,8 @@ service: retrieve: path: /accounting/v1/issues/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Get a specific issue. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/items.yml b/.mock/definition/Accounting/items.yml index cf491b7ea..81d180fe8 100644 --- a/.mock/definition/Accounting/items.yml +++ b/.mock/definition/Accounting/items.yml @@ -26,7 +26,8 @@ service: list: path: /accounting/v1/items method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Item` objects. pagination: cursor: $request.cursor @@ -107,7 +108,19 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -143,7 +156,8 @@ service: create: path: /accounting/v1/items method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Item` object with the given values. source: openapi: accounting_v3.yml @@ -167,7 +181,10 @@ service: type: accountingRoot.ItemResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -222,7 +239,8 @@ service: retrieve: path: /accounting/v1/items/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Item` object with the given `id`. source: openapi: accounting_v3.yml @@ -264,6 +282,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -296,7 +319,8 @@ service: partialUpdate: path: /accounting/v1/items/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates an `Item` object with the given `id`. source: openapi: accounting_v3.yml @@ -324,6 +348,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -379,7 +406,8 @@ service: metaPatchRetrieve: path: /accounting/v1/items/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Item` PATCHs. source: openapi: accounting_v3.yml @@ -568,7 +596,8 @@ service: metaPostRetrieve: path: /accounting/v1/items/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Item` POSTs. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/journalEntries.yml b/.mock/definition/Accounting/journalEntries.yml index 58a562f73..de400100f 100644 --- a/.mock/definition/Accounting/journalEntries.yml +++ b/.mock/definition/Accounting/journalEntries.yml @@ -28,7 +28,8 @@ service: list: path: /accounting/v1/journal-entries method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `JournalEntry` objects. pagination: cursor: $request.cursor @@ -112,7 +113,20 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + transaction_date_after: '2024-01-15T09:30:00Z' + transaction_date_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -183,7 +197,8 @@ service: create: path: /accounting/v1/journal-entries method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `JournalEntry` object with the given values. source: openapi: accounting_v3.yml @@ -207,7 +222,10 @@ service: type: accountingRoot.JournalEntryResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -297,7 +315,8 @@ service: retrieve: path: /accounting/v1/journal-entries/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `JournalEntry` object with the given `id`. source: openapi: accounting_v3.yml @@ -334,6 +353,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -421,7 +444,8 @@ service: linesRemoteFieldClassesList: path: /accounting/v1/journal-entries/lines/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -473,6 +497,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -493,7 +523,8 @@ service: metaPostRetrieve: path: /accounting/v1/journal-entries/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `JournalEntry` POSTs. source: openapi: accounting_v3.yml @@ -678,7 +709,8 @@ service: remoteFieldClassesList: path: /accounting/v1/journal-entries/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -730,6 +762,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/linkToken.yml b/.mock/definition/Accounting/linkToken.yml index a0e48ebe5..4d3d29cdf 100644 --- a/.mock/definition/Accounting/linkToken.yml +++ b/.mock/definition/Accounting/linkToken.yml @@ -24,7 +24,8 @@ service: create: path: /accounting/v1/link-token method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a link token to be used when linking a new end user. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/linkedAccounts.yml b/.mock/definition/Accounting/linkedAccounts.yml index ec15b619d..b3382911a 100644 --- a/.mock/definition/Accounting/linkedAccounts.yml +++ b/.mock/definition/Accounting/linkedAccounts.yml @@ -19,7 +19,8 @@ service: list: path: /accounting/v1/linked-accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: List linked accounts for your organization. pagination: cursor: $request.cursor @@ -112,7 +113,19 @@ service: status-code: 200 examples: - query-parameters: + category: accounting cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_user_email_address: end_user_email_address + end_user_organization_name: end_user_organization_name + end_user_origin_id: end_user_origin_id + end_user_origin_ids: end_user_origin_ids + id: id + ids: ids + include_duplicates: true + integration_name: integration_name + is_test_account: is_test_account + page_size: 1 + status: status headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/Accounting/passthrough.yml b/.mock/definition/Accounting/passthrough.yml index 06fefb4b8..5815ec9d1 100644 --- a/.mock/definition/Accounting/passthrough.yml +++ b/.mock/definition/Accounting/passthrough.yml @@ -7,7 +7,8 @@ service: create: path: /accounting/v1/passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: Pull data from an endpoint not currently supported by Merge. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/paymentMethods.yml b/.mock/definition/Accounting/paymentMethods.yml index 18fc7f5c5..8d1a36848 100644 --- a/.mock/definition/Accounting/paymentMethods.yml +++ b/.mock/definition/Accounting/paymentMethods.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/payment-methods method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `PaymentMethod` objects. pagination: cursor: $request.cursor @@ -49,6 +50,10 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -76,7 +81,8 @@ service: retrieve: path: /accounting/v1/payment-methods/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `PaymentMethod` object with the given `id`. source: openapi: accounting_v3.yml @@ -102,6 +108,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/paymentTerms.yml b/.mock/definition/Accounting/paymentTerms.yml index af1d567d3..f1f342931 100644 --- a/.mock/definition/Accounting/paymentTerms.yml +++ b/.mock/definition/Accounting/paymentTerms.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/payment-terms method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `PaymentTerm` objects. pagination: cursor: $request.cursor @@ -55,6 +56,10 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -84,7 +89,8 @@ service: retrieve: path: /accounting/v1/payment-terms/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `PaymentTerm` object with the given `id`. source: openapi: accounting_v3.yml @@ -116,6 +122,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/payments.yml b/.mock/definition/Accounting/payments.yml index 58b58f70e..2bd53ed62 100644 --- a/.mock/definition/Accounting/payments.yml +++ b/.mock/definition/Accounting/payments.yml @@ -30,7 +30,8 @@ service: list: path: /accounting/v1/payments method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Payment` objects. pagination: cursor: $request.cursor @@ -120,7 +121,22 @@ service: status-code: 200 examples: - query-parameters: + account_id: account_id + company_id: company_id + contact_id: contact_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + transaction_date_after: '2024-01-15T09:30:00Z' + transaction_date_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -179,7 +195,8 @@ service: create: path: /accounting/v1/payments method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Payment` object with the given values. source: openapi: accounting_v3.yml @@ -203,7 +220,10 @@ service: type: accountingRoot.PaymentResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -281,7 +301,8 @@ service: retrieve: path: /accounting/v1/payments/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Payment` object with the given `id`. source: openapi: accounting_v3.yml @@ -318,6 +339,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -375,7 +400,8 @@ service: partialUpdate: path: /accounting/v1/payments/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates a `Payment` object with the given `id`. source: openapi: accounting_v3.yml @@ -403,6 +429,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -481,7 +510,8 @@ service: lineItemsRemoteFieldClassesList: path: /accounting/v1/payments/line-items/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -533,6 +563,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -553,7 +589,8 @@ service: metaPatchRetrieve: path: /accounting/v1/payments/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Payment` PATCHs. source: openapi: accounting_v3.yml @@ -742,7 +779,8 @@ service: metaPostRetrieve: path: /accounting/v1/payments/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Payment` POSTs. source: openapi: accounting_v3.yml @@ -927,7 +965,8 @@ service: remoteFieldClassesList: path: /accounting/v1/payments/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -979,6 +1018,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/phoneNumbers.yml b/.mock/definition/Accounting/phoneNumbers.yml index 25e95a031..d5d8e3d13 100644 --- a/.mock/definition/Accounting/phoneNumbers.yml +++ b/.mock/definition/Accounting/phoneNumbers.yml @@ -7,7 +7,8 @@ service: retrieve: path: /accounting/v1/phone-numbers/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `AccountingPhoneNumber` object with the given `id`. source: openapi: accounting_v3.yml @@ -33,6 +34,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/projects.yml b/.mock/definition/Accounting/projects.yml index b000193c4..b4c587c2a 100644 --- a/.mock/definition/Accounting/projects.yml +++ b/.mock/definition/Accounting/projects.yml @@ -20,7 +20,8 @@ service: list: path: /accounting/v1/projects method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Project` objects. source: openapi: accounting_v3.yml @@ -64,6 +65,10 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -91,7 +96,8 @@ service: retrieve: path: /accounting/v1/projects/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Project` object with the given `id`. source: openapi: accounting_v3.yml @@ -123,6 +129,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/purchaseOrders.yml b/.mock/definition/Accounting/purchaseOrders.yml index dcd7fe340..54247abdb 100644 --- a/.mock/definition/Accounting/purchaseOrders.yml +++ b/.mock/definition/Accounting/purchaseOrders.yml @@ -30,7 +30,8 @@ service: list: path: /accounting/v1/purchase-orders method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `PurchaseOrder` objects. pagination: cursor: $request.cursor @@ -124,7 +125,22 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + issue_date_after: '2024-01-15T09:30:00Z' + issue_date_before: '2024-01-15T09:30:00Z' + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -205,7 +221,8 @@ service: create: path: /accounting/v1/purchase-orders method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `PurchaseOrder` object with the given values. source: openapi: accounting_v3.yml @@ -229,7 +246,10 @@ service: type: accountingRoot.PurchaseOrderResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -329,7 +349,8 @@ service: retrieve: path: /accounting/v1/purchase-orders/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `PurchaseOrder` object with the given `id`. source: openapi: accounting_v3.yml @@ -376,6 +397,12 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -467,7 +494,8 @@ service: lineItemsRemoteFieldClassesList: path: /accounting/v1/purchase-orders/line-items/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -519,6 +547,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -539,7 +573,8 @@ service: metaPostRetrieve: path: /accounting/v1/purchase-orders/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `PurchaseOrder` POSTs. source: openapi: accounting_v3.yml @@ -724,7 +759,8 @@ service: remoteFieldClassesList: path: /accounting/v1/purchase-orders/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -776,6 +812,12 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/regenerateKey.yml b/.mock/definition/Accounting/regenerateKey.yml index 3f735c164..3fabcb13a 100644 --- a/.mock/definition/Accounting/regenerateKey.yml +++ b/.mock/definition/Accounting/regenerateKey.yml @@ -7,7 +7,8 @@ service: create: path: /accounting/v1/regenerate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Exchange remote keys. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/scopes.yml b/.mock/definition/Accounting/scopes.yml index 329794ec3..c0e2e7558 100644 --- a/.mock/definition/Accounting/scopes.yml +++ b/.mock/definition/Accounting/scopes.yml @@ -7,7 +7,8 @@ service: default_scopes_retrieve: path: /accounting/v1/default-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn @@ -50,7 +51,8 @@ service: linked_account_scopes_retrieve: path: /accounting/v1/linked-account-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn @@ -93,7 +95,8 @@ service: linked_account_scopes_create: path: /accounting/v1/linked-account-scopes method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the diff --git a/.mock/definition/Accounting/syncStatus.yml b/.mock/definition/Accounting/syncStatus.yml index c8fa8fa5f..bb6eaf28e 100644 --- a/.mock/definition/Accounting/syncStatus.yml +++ b/.mock/definition/Accounting/syncStatus.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/sync-status method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. @@ -42,6 +43,7 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/taxRates.yml b/.mock/definition/Accounting/taxRates.yml index 7bfa93f15..e2fedf7a5 100644 --- a/.mock/definition/Accounting/taxRates.yml +++ b/.mock/definition/Accounting/taxRates.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/tax-rates method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `TaxRate` objects. pagination: cursor: $request.cursor @@ -81,7 +82,18 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -123,7 +135,8 @@ service: retrieve: path: /accounting/v1/tax-rates/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `TaxRate` object with the given `id`. source: openapi: accounting_v3.yml @@ -155,6 +168,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/trackingCategories.yml b/.mock/definition/Accounting/trackingCategories.yml index b2323394f..92b731f2a 100644 --- a/.mock/definition/Accounting/trackingCategories.yml +++ b/.mock/definition/Accounting/trackingCategories.yml @@ -1,3 +1,20 @@ +types: + TrackingCategoriesListRequestCategoryType: + enum: + - value: '' + name: EMPTY + - CLASS + - DEPARTMENT + source: + openapi: accounting_v3.yml + TrackingCategoriesListRequestStatus: + enum: + - value: '' + name: EMPTY + - ACTIVE + - ARCHIVED + source: + openapi: accounting_v3.yml imports: accountingRoot: __package__.yml service: @@ -7,7 +24,8 @@ service: list: path: /accounting/v1/tracking-categories method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `TrackingCategory` objects. pagination: cursor: $request.cursor @@ -19,7 +37,7 @@ service: name: TrackingCategoriesListRequest query-parameters: category_type: - type: optional + type: optional docs: If provided, will only return tracking categories with this type. company_id: type: optional @@ -91,7 +109,7 @@ service: enum values. [Learn more](https://help.merge.dev/en/articles/8950958-show_enum_origins-query-parameter) status: - type: optional + type: optional docs: >- If provided, will only return tracking categories with this status. @@ -101,7 +119,22 @@ service: status-code: 200 examples: - query-parameters: + category_type: '' + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + page_size: 1 + remote_fields: status + remote_id: remote_id + show_enum_origins: status + status: '' headers: X-Account-Token: X-Account-Token response: @@ -127,7 +160,8 @@ service: retrieve: path: /accounting/v1/tracking-categories/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `TrackingCategory` object with the given `id`. source: openapi: accounting_v3.yml @@ -169,6 +203,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/transactions.yml b/.mock/definition/Accounting/transactions.yml index 8b0578081..480f38603 100644 --- a/.mock/definition/Accounting/transactions.yml +++ b/.mock/definition/Accounting/transactions.yml @@ -26,7 +26,8 @@ service: list: path: /accounting/v1/transactions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Transaction` objects. pagination: cursor: $request.cursor @@ -107,7 +108,19 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + transaction_date_after: '2024-01-15T09:30:00Z' + transaction_date_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -181,7 +194,8 @@ service: retrieve: path: /accounting/v1/transactions/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Transaction` object with the given `id`. source: openapi: accounting_v3.yml @@ -213,6 +227,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Accounting/vendorCredits.yml b/.mock/definition/Accounting/vendorCredits.yml index a33583cdf..1df382777 100644 --- a/.mock/definition/Accounting/vendorCredits.yml +++ b/.mock/definition/Accounting/vendorCredits.yml @@ -26,7 +26,8 @@ service: list: path: /accounting/v1/vendor-credits method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `VendorCredit` objects. pagination: cursor: $request.cursor @@ -105,7 +106,19 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + transaction_date_after: '2024-01-15T09:30:00Z' + transaction_date_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -178,7 +191,8 @@ service: create: path: /accounting/v1/vendor-credits method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `VendorCredit` object with the given values. source: openapi: accounting_v3.yml @@ -202,7 +216,10 @@ service: type: accountingRoot.VendorCreditResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -294,7 +311,8 @@ service: retrieve: path: /accounting/v1/vendor-credits/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `VendorCredit` object with the given `id`. source: openapi: accounting_v3.yml @@ -326,6 +344,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -403,7 +424,8 @@ service: metaPostRetrieve: path: /accounting/v1/vendor-credits/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `VendorCredit` POSTs. source: openapi: accounting_v3.yml diff --git a/.mock/definition/Accounting/webhookReceivers.yml b/.mock/definition/Accounting/webhookReceivers.yml index e1a4b30ae..eb04b349d 100644 --- a/.mock/definition/Accounting/webhookReceivers.yml +++ b/.mock/definition/Accounting/webhookReceivers.yml @@ -7,7 +7,8 @@ service: list: path: /accounting/v1/webhook-receivers method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `WebhookReceiver` objects. source: openapi: accounting_v3.yml @@ -26,7 +27,8 @@ service: create: path: /accounting/v1/webhook-receivers method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `WebhookReceiver` object with the given values. source: openapi: accounting_v3.yml diff --git a/.mock/definition/CRM/accountDetails.yml b/.mock/definition/CRM/accountDetails.yml index 42bd1c692..a624217a6 100644 --- a/.mock/definition/CRM/accountDetails.yml +++ b/.mock/definition/CRM/accountDetails.yml @@ -7,7 +7,8 @@ service: retrieve: path: /crm/v1/account-details method: GET - auth: true + auth: + - tokenAuth: [] docs: Get details for a linked account. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/accountToken.yml b/.mock/definition/CRM/accountToken.yml index b9ac409e6..a58e52063 100644 --- a/.mock/definition/CRM/accountToken.yml +++ b/.mock/definition/CRM/accountToken.yml @@ -7,7 +7,8 @@ service: retrieve: path: /crm/v1/account-token/{public_token} method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns the account token for the end user with the provided public token. diff --git a/.mock/definition/CRM/accounts.yml b/.mock/definition/CRM/accounts.yml index a64da124c..e92b3aef2 100644 --- a/.mock/definition/CRM/accounts.yml +++ b/.mock/definition/CRM/accounts.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Account` objects. pagination: cursor: $request.cursor @@ -86,7 +87,19 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + owner_id: owner_id + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -137,7 +150,8 @@ service: create: path: /crm/v1/accounts method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Account` object with the given values. source: openapi: crm_v3.yml @@ -161,7 +175,10 @@ service: type: crmRoot.CrmAccountResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -231,7 +248,8 @@ service: retrieve: path: /crm/v1/accounts/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Account` object with the given `id`. source: openapi: crm_v3.yml @@ -268,6 +286,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -317,7 +339,8 @@ service: partialUpdate: path: /crm/v1/accounts/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates an `Account` object with the given `id`. source: openapi: crm_v3.yml @@ -345,6 +368,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -415,7 +441,8 @@ service: metaPatchRetrieve: path: /crm/v1/accounts/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `CRMAccount` PATCHs. source: openapi: crm_v3.yml @@ -604,7 +631,8 @@ service: metaPostRetrieve: path: /crm/v1/accounts/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `CRMAccount` POSTs. source: openapi: crm_v3.yml @@ -789,7 +817,8 @@ service: remoteFieldClassesList: path: /crm/v1/accounts/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -846,6 +875,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/associationTypes.yml b/.mock/definition/CRM/associationTypes.yml index 860050e4d..309496c42 100644 --- a/.mock/definition/CRM/associationTypes.yml +++ b/.mock/definition/CRM/associationTypes.yml @@ -7,7 +7,8 @@ service: custom_object_classes_association_types_list: path: /crm/v1/custom-object-classes/{custom_object_class_id}/association-types method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `AssociationType` objects. pagination: cursor: $request.cursor @@ -79,7 +80,16 @@ service: - path-parameters: custom_object_class_id: custom_object_class_id query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -104,7 +114,8 @@ service: custom_object_classes_association_types_create: path: /crm/v1/custom-object-classes/{custom_object_class_id}/association-types method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `AssociationType` object with the given values. source: openapi: crm_v3.yml @@ -132,6 +143,9 @@ service: examples: - path-parameters: custom_object_class_id: custom_object_class_id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -184,7 +198,8 @@ service: path: >- /crm/v1/custom-object-classes/{custom_object_class_id}/association-types/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `AssociationType` object with the given `id`. source: openapi: crm_v3.yml @@ -218,6 +233,9 @@ service: - path-parameters: custom_object_class_id: custom_object_class_id id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -242,7 +260,8 @@ service: path: >- /crm/v1/custom-object-classes/{custom_object_class_id}/association-types/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `CRMAssociationType` POSTs. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/associations.yml b/.mock/definition/CRM/associations.yml index 478198489..435eb2445 100644 --- a/.mock/definition/CRM/associations.yml +++ b/.mock/definition/CRM/associations.yml @@ -8,7 +8,8 @@ service: path: >- /crm/v1/custom-object-classes/{custom_object_class_id}/custom-objects/{object_id}/associations method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Association` objects. pagination: cursor: $request.cursor @@ -87,7 +88,17 @@ service: custom_object_class_id: custom_object_class_id object_id: object_id query-parameters: + association_type_id: association_type_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -104,18 +115,19 @@ service: path: >- /crm/v1/custom-object-classes/{source_class_id}/custom-objects/{source_object_id}/associations/{target_class_id}/{target_object_id}/{association_type_id} method: PUT - auth: true + auth: + - tokenAuth: [] docs: >- Creates an Association between `source_object_id` and `target_object_id` of type `association_type_id`. source: openapi: crm_v3.yml path-parameters: - association_type_id: string source_class_id: string source_object_id: string target_class_id: string target_object_id: string + association_type_id: string request: name: CustomObjectClassesCustomObjectsAssociationsUpdateRequest query-parameters: @@ -133,11 +145,14 @@ service: status-code: 200 examples: - path-parameters: - association_type_id: association_type_id source_class_id: source_class_id source_object_id: source_object_id target_class_id: target_class_id target_object_id: target_object_id + association_type_id: association_type_id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/asyncPassthrough.yml b/.mock/definition/CRM/asyncPassthrough.yml index 2185ef19b..ee3155643 100644 --- a/.mock/definition/CRM/asyncPassthrough.yml +++ b/.mock/definition/CRM/asyncPassthrough.yml @@ -7,7 +7,8 @@ service: create: path: /crm/v1/async-passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Asynchronously pull data from an endpoint not currently supported by Merge. @@ -32,7 +33,8 @@ service: retrieve: path: /crm/v1/async-passthrough/{async_passthrough_receipt_id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Retrieves data from earlier async-passthrough POST request source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/auditTrail.yml b/.mock/definition/CRM/auditTrail.yml index 2e98a5a88..e12fd4751 100644 --- a/.mock/definition/CRM/auditTrail.yml +++ b/.mock/definition/CRM/auditTrail.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/audit-trail method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets a list of audit trail events. pagination: cursor: $request.cursor @@ -81,6 +82,11 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + event_type: event_type + page_size: 1 + start_date: start_date + user_email: user_email headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/CRM/availableActions.yml b/.mock/definition/CRM/availableActions.yml index cc72be6b4..44a78dad2 100644 --- a/.mock/definition/CRM/availableActions.yml +++ b/.mock/definition/CRM/availableActions.yml @@ -7,7 +7,8 @@ service: retrieve: path: /crm/v1/available-actions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of models and actions available for an account. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/contacts.yml b/.mock/definition/CRM/contacts.yml index 75622c011..c9b501e3f 100644 --- a/.mock/definition/CRM/contacts.yml +++ b/.mock/definition/CRM/contacts.yml @@ -20,7 +20,8 @@ service: list: path: /crm/v1/contacts method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Contact` objects. pagination: cursor: $request.cursor @@ -106,7 +107,20 @@ service: status-code: 200 examples: - query-parameters: + account_id: account_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + email_addresses: email_addresses + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + phone_numbers: phone_numbers + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -159,7 +173,8 @@ service: create: path: /crm/v1/contacts method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Contact` object with the given values. source: openapi: crm_v3.yml @@ -183,7 +198,10 @@ service: type: crmRoot.CrmContactResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -255,7 +273,8 @@ service: retrieve: path: /crm/v1/contacts/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Contact` object with the given `id`. source: openapi: crm_v3.yml @@ -292,6 +311,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -343,7 +366,8 @@ service: partialUpdate: path: /crm/v1/contacts/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates a `Contact` object with the given `id`. source: openapi: crm_v3.yml @@ -371,6 +395,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -443,7 +470,8 @@ service: ignoreCreate: path: /crm/v1/contacts/ignore/{model_id} method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in @@ -466,7 +494,8 @@ service: metaPatchRetrieve: path: /crm/v1/contacts/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `CRMContact` PATCHs. source: openapi: crm_v3.yml @@ -655,7 +684,8 @@ service: metaPostRetrieve: path: /crm/v1/contacts/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `CRMContact` POSTs. source: openapi: crm_v3.yml @@ -840,7 +870,8 @@ service: remoteFieldClassesList: path: /crm/v1/contacts/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -897,6 +928,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/customObjectClasses.yml b/.mock/definition/CRM/customObjectClasses.yml index 0347a1d28..abba319aa 100644 --- a/.mock/definition/CRM/customObjectClasses.yml +++ b/.mock/definition/CRM/customObjectClasses.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/custom-object-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `CustomObjectClass` objects. pagination: cursor: $request.cursor @@ -75,7 +76,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -101,6 +111,10 @@ service: field_format: string field_choices: - {} + item_schema: + item_type: null + item_format: null + item_choices: null - display_name: Order Quantity remote_key_name: order_quantity description: The number of items ordered. @@ -109,6 +123,10 @@ service: field_format: number field_choices: - {} + item_schema: + item_type: null + item_format: null + item_choices: null - display_name: Customer Type remote_key_name: customer_type description: The type of customer. @@ -123,7 +141,8 @@ service: retrieve: path: /crm/v1/custom-object-classes/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `CustomObjectClass` object with the given `id`. source: openapi: crm_v3.yml @@ -155,6 +174,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -179,6 +201,10 @@ service: field_format: string field_choices: - {} + item_schema: + item_type: null + item_format: null + item_choices: null - created_at: '2024-01-15T09:30:00Z' modified_at: '2024-01-15T09:30:00Z' display_name: Order Quantity @@ -189,6 +215,10 @@ service: field_format: number field_choices: - {} + item_schema: + item_type: null + item_format: null + item_choices: null - created_at: '2024-01-15T09:30:00Z' modified_at: '2024-01-15T09:30:00Z' display_name: Customer Type diff --git a/.mock/definition/CRM/customObjects.yml b/.mock/definition/CRM/customObjects.yml index e55db8a3c..ac8b5453c 100644 --- a/.mock/definition/CRM/customObjects.yml +++ b/.mock/definition/CRM/customObjects.yml @@ -7,7 +7,8 @@ service: custom_object_classes_custom_objects_list: path: /crm/v1/custom-object-classes/{custom_object_class_id}/custom-objects method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `CustomObject` objects. pagination: cursor: $request.cursor @@ -78,7 +79,17 @@ service: - path-parameters: custom_object_class_id: custom_object_class_id query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -100,7 +111,8 @@ service: custom_object_classes_custom_objects_create: path: /crm/v1/custom-object-classes/{custom_object_class_id}/custom-objects method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `CustomObject` object with the given values. source: openapi: crm_v3.yml @@ -128,6 +140,9 @@ service: examples: - path-parameters: custom_object_class_id: custom_object_class_id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -172,7 +187,8 @@ service: path: >- /crm/v1/custom-object-classes/{custom_object_class_id}/custom-objects/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `CustomObject` object with the given `id`. source: openapi: crm_v3.yml @@ -205,6 +221,10 @@ service: - path-parameters: custom_object_class_id: custom_object_class_id id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -226,7 +246,8 @@ service: path: >- /crm/v1/custom-object-classes/{custom_object_class_id}/custom-objects/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `CRMCustomObject` POSTs. source: openapi: crm_v3.yml @@ -415,7 +436,8 @@ service: custom_object_classes_custom_objects_remote_field_classes_list: path: /crm/v1/custom-object-classes/custom-objects/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -472,6 +494,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/deleteAccount.yml b/.mock/definition/CRM/deleteAccount.yml index 07f83ee89..38084283f 100644 --- a/.mock/definition/CRM/deleteAccount.yml +++ b/.mock/definition/CRM/deleteAccount.yml @@ -5,7 +5,8 @@ service: delete: path: /crm/v1/delete-account method: POST - auth: true + auth: + - tokenAuth: [] docs: Delete a linked account. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/engagementTypes.yml b/.mock/definition/CRM/engagementTypes.yml index b5567928d..f4d2dbfd5 100644 --- a/.mock/definition/CRM/engagementTypes.yml +++ b/.mock/definition/CRM/engagementTypes.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/engagement-types method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `EngagementType` objects. pagination: cursor: $request.cursor @@ -74,7 +75,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -93,7 +104,8 @@ service: retrieve: path: /crm/v1/engagement-types/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `EngagementType` object with the given `id`. source: openapi: crm_v3.yml @@ -124,6 +136,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -141,7 +157,8 @@ service: remoteFieldClassesList: path: /crm/v1/engagement-types/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -198,6 +215,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/engagements.yml b/.mock/definition/CRM/engagements.yml index 19f77c10c..194abfdc0 100644 --- a/.mock/definition/CRM/engagements.yml +++ b/.mock/definition/CRM/engagements.yml @@ -24,7 +24,8 @@ service: list: path: /crm/v1/engagements method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Engagement` objects. pagination: cursor: $request.cursor @@ -107,7 +108,19 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + started_after: '2024-01-15T09:30:00Z' + started_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -144,7 +157,8 @@ service: create: path: /crm/v1/engagements method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Engagement` object with the given values. source: openapi: crm_v3.yml @@ -168,7 +182,10 @@ service: type: crmRoot.EngagementResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -224,7 +241,8 @@ service: retrieve: path: /crm/v1/engagements/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Engagement` object with the given `id`. source: openapi: crm_v3.yml @@ -261,6 +279,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -296,7 +318,8 @@ service: partialUpdate: path: /crm/v1/engagements/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates an `Engagement` object with the given `id`. source: openapi: crm_v3.yml @@ -324,6 +347,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -380,7 +406,8 @@ service: metaPatchRetrieve: path: /crm/v1/engagements/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Engagement` PATCHs. source: openapi: crm_v3.yml @@ -569,7 +596,8 @@ service: metaPostRetrieve: path: /crm/v1/engagements/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Engagement` POSTs. source: openapi: crm_v3.yml @@ -754,7 +782,8 @@ service: remoteFieldClassesList: path: /crm/v1/engagements/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -811,6 +840,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/fieldMapping.yml b/.mock/definition/CRM/fieldMapping.yml index a31caaf36..efd75ffee 100644 --- a/.mock/definition/CRM/fieldMapping.yml +++ b/.mock/definition/CRM/fieldMapping.yml @@ -7,7 +7,8 @@ service: field_mappings_retrieve: path: /crm/v1/field-mappings method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge @@ -30,7 +31,9 @@ service: type: crmRoot.FieldMappingApiInstanceResponse status-code: 200 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token response: body: @@ -181,7 +184,8 @@ service: field_mappings_create: path: /crm/v1/field-mappings method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to @@ -246,7 +250,9 @@ service: type: crmRoot.FieldMappingInstanceResponse status-code: 201 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token request: target_field_name: example_target_field_name @@ -297,7 +303,8 @@ service: field_mappings_destroy: path: /crm/v1/field-mappings/{field_mapping_id} method: DELETE - auth: true + auth: + - tokenAuth: [] docs: >- Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after @@ -357,7 +364,8 @@ service: field_mappings_partial_update: path: /crm/v1/field-mappings/{field_mapping_id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: >- Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the @@ -441,7 +449,8 @@ service: remote_fields_retrieve: path: /crm/v1/remote-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data @@ -469,7 +478,10 @@ service: type: crmRoot.RemoteFieldApiResponse status-code: 200 examples: - - headers: + - query-parameters: + common_models: common_models + include_example_values: include_example_values + headers: X-Account-Token: X-Account-Token response: body: @@ -602,7 +614,8 @@ service: target_fields_retrieve: path: /crm/v1/target-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields diff --git a/.mock/definition/CRM/forceResync.yml b/.mock/definition/CRM/forceResync.yml index f05a91fd9..0e4c7b717 100644 --- a/.mock/definition/CRM/forceResync.yml +++ b/.mock/definition/CRM/forceResync.yml @@ -7,7 +7,8 @@ service: sync_status_resync_create: path: /crm/v1/sync-status/resync method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or diff --git a/.mock/definition/CRM/generateKey.yml b/.mock/definition/CRM/generateKey.yml index e91da902a..939253df9 100644 --- a/.mock/definition/CRM/generateKey.yml +++ b/.mock/definition/CRM/generateKey.yml @@ -7,7 +7,8 @@ service: create: path: /crm/v1/generate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Create a remote key. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/issues.yml b/.mock/definition/CRM/issues.yml index 302a87a1d..5f20722df 100644 --- a/.mock/definition/CRM/issues.yml +++ b/.mock/definition/CRM/issues.yml @@ -14,7 +14,8 @@ service: list: path: /crm/v1/issues method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets all issues for Organization. pagination: cursor: $request.cursor @@ -85,7 +86,20 @@ service: status-code: 200 examples: - query-parameters: + account_token: account_token cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + end_user_organization_name: end_user_organization_name + first_incident_time_after: '2024-01-15T09:30:00Z' + first_incident_time_before: '2024-01-15T09:30:00Z' + include_muted: include_muted + integration_name: integration_name + last_incident_time_after: '2024-01-15T09:30:00Z' + last_incident_time_before: '2024-01-15T09:30:00Z' + linked_account_id: linked_account_id + page_size: 1 + start_date: start_date + status: ONGOING headers: X-Account-Token: '[object Object]' response: @@ -107,7 +121,8 @@ service: retrieve: path: /crm/v1/issues/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Get a specific issue. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/leads.yml b/.mock/definition/CRM/leads.yml index affed658f..8533bc14d 100644 --- a/.mock/definition/CRM/leads.yml +++ b/.mock/definition/CRM/leads.yml @@ -22,7 +22,8 @@ service: list: path: /crm/v1/leads method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Lead` objects. pagination: cursor: $request.cursor @@ -114,7 +115,22 @@ service: status-code: 200 examples: - query-parameters: + converted_account_id: converted_account_id + converted_contact_id: converted_contact_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + email_addresses: email_addresses + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + owner_id: owner_id + page_size: 1 + phone_numbers: phone_numbers + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -172,7 +188,8 @@ service: create: path: /crm/v1/leads method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Lead` object with the given values. source: openapi: crm_v3.yml @@ -196,7 +213,10 @@ service: type: crmRoot.LeadResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -273,7 +293,8 @@ service: retrieve: path: /crm/v1/leads/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Lead` object with the given `id`. source: openapi: crm_v3.yml @@ -310,6 +331,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -366,7 +391,8 @@ service: metaPostRetrieve: path: /crm/v1/leads/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Lead` POSTs. source: openapi: crm_v3.yml @@ -551,7 +577,8 @@ service: remoteFieldClassesList: path: /crm/v1/leads/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -608,6 +635,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/linkToken.yml b/.mock/definition/CRM/linkToken.yml index 3c88a7e1b..b1945f329 100644 --- a/.mock/definition/CRM/linkToken.yml +++ b/.mock/definition/CRM/linkToken.yml @@ -24,7 +24,8 @@ service: create: path: /crm/v1/link-token method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a link token to be used when linking a new end user. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/linkedAccounts.yml b/.mock/definition/CRM/linkedAccounts.yml index 28486065c..f938ea57b 100644 --- a/.mock/definition/CRM/linkedAccounts.yml +++ b/.mock/definition/CRM/linkedAccounts.yml @@ -19,7 +19,8 @@ service: list: path: /crm/v1/linked-accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: List linked accounts for your organization. pagination: cursor: $request.cursor @@ -112,7 +113,19 @@ service: status-code: 200 examples: - query-parameters: + category: accounting cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_user_email_address: end_user_email_address + end_user_organization_name: end_user_organization_name + end_user_origin_id: end_user_origin_id + end_user_origin_ids: end_user_origin_ids + id: id + ids: ids + include_duplicates: true + integration_name: integration_name + is_test_account: is_test_account + page_size: 1 + status: status headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/CRM/notes.yml b/.mock/definition/CRM/notes.yml index f03aad2b0..de0873c39 100644 --- a/.mock/definition/CRM/notes.yml +++ b/.mock/definition/CRM/notes.yml @@ -24,7 +24,8 @@ service: list: path: /crm/v1/notes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Note` objects. pagination: cursor: $request.cursor @@ -109,7 +110,21 @@ service: status-code: 200 examples: - query-parameters: + account_id: account_id + contact_id: contact_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + opportunity_id: opportunity_id + owner_id: owner_id + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -143,7 +158,8 @@ service: create: path: /crm/v1/notes method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Note` object with the given values. source: openapi: crm_v3.yml @@ -167,7 +183,10 @@ service: type: crmRoot.NoteResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -220,7 +239,8 @@ service: retrieve: path: /crm/v1/notes/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Note` object with the given `id`. source: openapi: crm_v3.yml @@ -257,6 +277,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -289,7 +313,8 @@ service: metaPostRetrieve: path: /crm/v1/notes/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Note` POSTs. source: openapi: crm_v3.yml @@ -474,7 +499,8 @@ service: remoteFieldClassesList: path: /crm/v1/notes/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -531,6 +557,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/opportunities.yml b/.mock/definition/CRM/opportunities.yml index 4f33dae8d..5b149aa5d 100644 --- a/.mock/definition/CRM/opportunities.yml +++ b/.mock/definition/CRM/opportunities.yml @@ -29,7 +29,8 @@ service: list: path: /crm/v1/opportunities method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Opportunity` objects. pagination: cursor: $request.cursor @@ -138,7 +139,24 @@ service: status-code: 200 examples: - query-parameters: + account_id: account_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + owner_id: owner_id + page_size: 1 + remote_created_after: '2024-01-15T09:30:00Z' + remote_fields: status + remote_id: remote_id + show_enum_origins: status + stage_id: stage_id + status: LOST headers: X-Account-Token: X-Account-Token response: @@ -175,7 +193,8 @@ service: create: path: /crm/v1/opportunities method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Opportunity` object with the given values. source: openapi: crm_v3.yml @@ -199,7 +218,10 @@ service: type: crmRoot.OpportunityResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -255,7 +277,8 @@ service: retrieve: path: /crm/v1/opportunities/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Opportunity` object with the given `id`. source: openapi: crm_v3.yml @@ -302,6 +325,12 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true + remote_fields: status + show_enum_origins: status headers: X-Account-Token: X-Account-Token response: @@ -337,7 +366,8 @@ service: partialUpdate: path: /crm/v1/opportunities/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates an `Opportunity` object with the given `id`. source: openapi: crm_v3.yml @@ -365,6 +395,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -421,7 +454,8 @@ service: metaPatchRetrieve: path: /crm/v1/opportunities/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Opportunity` PATCHs. source: openapi: crm_v3.yml @@ -610,7 +644,8 @@ service: metaPostRetrieve: path: /crm/v1/opportunities/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Opportunity` POSTs. source: openapi: crm_v3.yml @@ -795,7 +830,8 @@ service: remoteFieldClassesList: path: /crm/v1/opportunities/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -852,6 +888,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/passthrough.yml b/.mock/definition/CRM/passthrough.yml index d31ce9ca9..98ff45f26 100644 --- a/.mock/definition/CRM/passthrough.yml +++ b/.mock/definition/CRM/passthrough.yml @@ -7,7 +7,8 @@ service: create: path: /crm/v1/passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: Pull data from an endpoint not currently supported by Merge. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/regenerateKey.yml b/.mock/definition/CRM/regenerateKey.yml index 864b9e4bb..a926ee2a5 100644 --- a/.mock/definition/CRM/regenerateKey.yml +++ b/.mock/definition/CRM/regenerateKey.yml @@ -7,7 +7,8 @@ service: create: path: /crm/v1/regenerate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Exchange remote keys. source: openapi: crm_v3.yml diff --git a/.mock/definition/CRM/scopes.yml b/.mock/definition/CRM/scopes.yml index 3262c1b69..1c60baaea 100644 --- a/.mock/definition/CRM/scopes.yml +++ b/.mock/definition/CRM/scopes.yml @@ -7,7 +7,8 @@ service: default_scopes_retrieve: path: /crm/v1/default-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn @@ -50,7 +51,8 @@ service: linked_account_scopes_retrieve: path: /crm/v1/linked-account-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn @@ -93,7 +95,8 @@ service: linked_account_scopes_create: path: /crm/v1/linked-account-scopes method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the diff --git a/.mock/definition/CRM/stages.yml b/.mock/definition/CRM/stages.yml index a11e5413e..74830b933 100644 --- a/.mock/definition/CRM/stages.yml +++ b/.mock/definition/CRM/stages.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/stages method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Stage` objects. pagination: cursor: $request.cursor @@ -74,7 +75,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -102,7 +113,8 @@ service: retrieve: path: /crm/v1/stages/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Stage` object with the given `id`. source: openapi: crm_v3.yml @@ -133,6 +145,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -159,7 +175,8 @@ service: remoteFieldClassesList: path: /crm/v1/stages/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -216,6 +233,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/syncStatus.yml b/.mock/definition/CRM/syncStatus.yml index 00c570dab..ec796fcbf 100644 --- a/.mock/definition/CRM/syncStatus.yml +++ b/.mock/definition/CRM/syncStatus.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/sync-status method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. @@ -38,6 +39,7 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/tasks.yml b/.mock/definition/CRM/tasks.yml index 2528cbce1..b91eaeb7d 100644 --- a/.mock/definition/CRM/tasks.yml +++ b/.mock/definition/CRM/tasks.yml @@ -22,7 +22,8 @@ service: list: path: /crm/v1/tasks method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Task` objects. pagination: cursor: $request.cursor @@ -95,7 +96,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -130,7 +141,8 @@ service: create: path: /crm/v1/tasks method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Task` object with the given values. source: openapi: crm_v3.yml @@ -154,7 +166,10 @@ service: type: crmRoot.TaskResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -208,7 +223,8 @@ service: retrieve: path: /crm/v1/tasks/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Task` object with the given `id`. source: openapi: crm_v3.yml @@ -245,6 +261,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -278,7 +298,8 @@ service: partialUpdate: path: /crm/v1/tasks/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates a `Task` object with the given `id`. source: openapi: crm_v3.yml @@ -306,6 +327,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -360,7 +384,8 @@ service: metaPatchRetrieve: path: /crm/v1/tasks/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Task` PATCHs. source: openapi: crm_v3.yml @@ -549,7 +574,8 @@ service: metaPostRetrieve: path: /crm/v1/tasks/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Task` POSTs. source: openapi: crm_v3.yml @@ -734,7 +760,8 @@ service: remoteFieldClassesList: path: /crm/v1/tasks/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -791,6 +818,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/users.yml b/.mock/definition/CRM/users.yml index a97711f64..350a5a29e 100644 --- a/.mock/definition/CRM/users.yml +++ b/.mock/definition/CRM/users.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/users method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `User` objects. pagination: cursor: $request.cursor @@ -77,7 +78,18 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + email: email + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -107,7 +119,8 @@ service: retrieve: path: /crm/v1/users/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `User` object with the given `id`. source: openapi: crm_v3.yml @@ -138,6 +151,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -166,7 +183,8 @@ service: ignoreCreate: path: /crm/v1/users/ignore/{model_id} method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in @@ -189,7 +207,8 @@ service: remoteFieldClassesList: path: /crm/v1/users/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -246,6 +265,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/CRM/webhookReceivers.yml b/.mock/definition/CRM/webhookReceivers.yml index 2f5f9a1ce..03ae2b0cd 100644 --- a/.mock/definition/CRM/webhookReceivers.yml +++ b/.mock/definition/CRM/webhookReceivers.yml @@ -7,7 +7,8 @@ service: list: path: /crm/v1/webhook-receivers method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `WebhookReceiver` objects. source: openapi: crm_v3.yml @@ -26,7 +27,8 @@ service: create: path: /crm/v1/webhook-receivers method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `WebhookReceiver` object with the given values. source: openapi: crm_v3.yml diff --git a/.mock/definition/FileStorage/accountDetails.yml b/.mock/definition/FileStorage/accountDetails.yml index 3bde3779f..e6b0a3877 100644 --- a/.mock/definition/FileStorage/accountDetails.yml +++ b/.mock/definition/FileStorage/accountDetails.yml @@ -7,7 +7,8 @@ service: retrieve: path: /filestorage/v1/account-details method: GET - auth: true + auth: + - tokenAuth: [] docs: Get details for a linked account. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/accountToken.yml b/.mock/definition/FileStorage/accountToken.yml index 929023ba8..5027e47ca 100644 --- a/.mock/definition/FileStorage/accountToken.yml +++ b/.mock/definition/FileStorage/accountToken.yml @@ -7,7 +7,8 @@ service: retrieve: path: /filestorage/v1/account-token/{public_token} method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns the account token for the end user with the provided public token. diff --git a/.mock/definition/FileStorage/asyncPassthrough.yml b/.mock/definition/FileStorage/asyncPassthrough.yml index bd9089e14..917001aab 100644 --- a/.mock/definition/FileStorage/asyncPassthrough.yml +++ b/.mock/definition/FileStorage/asyncPassthrough.yml @@ -7,7 +7,8 @@ service: create: path: /filestorage/v1/async-passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Asynchronously pull data from an endpoint not currently supported by Merge. @@ -32,7 +33,8 @@ service: retrieve: path: /filestorage/v1/async-passthrough/{async_passthrough_receipt_id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Retrieves data from earlier async-passthrough POST request source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/auditTrail.yml b/.mock/definition/FileStorage/auditTrail.yml index 2c75a2e18..5147ae3f0 100644 --- a/.mock/definition/FileStorage/auditTrail.yml +++ b/.mock/definition/FileStorage/auditTrail.yml @@ -7,7 +7,8 @@ service: list: path: /filestorage/v1/audit-trail method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets a list of audit trail events. pagination: cursor: $request.cursor @@ -81,6 +82,11 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + event_type: event_type + page_size: 1 + start_date: start_date + user_email: user_email headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/FileStorage/availableActions.yml b/.mock/definition/FileStorage/availableActions.yml index b64491846..a9ab1fadd 100644 --- a/.mock/definition/FileStorage/availableActions.yml +++ b/.mock/definition/FileStorage/availableActions.yml @@ -7,7 +7,8 @@ service: retrieve: path: /filestorage/v1/available-actions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of models and actions available for an account. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/deleteAccount.yml b/.mock/definition/FileStorage/deleteAccount.yml index f9c48216f..767689fd2 100644 --- a/.mock/definition/FileStorage/deleteAccount.yml +++ b/.mock/definition/FileStorage/deleteAccount.yml @@ -5,7 +5,8 @@ service: delete: path: /filestorage/v1/delete-account method: POST - auth: true + auth: + - tokenAuth: [] docs: Delete a linked account. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/drives.yml b/.mock/definition/FileStorage/drives.yml index b8649b4c8..d02d4f3dd 100644 --- a/.mock/definition/FileStorage/drives.yml +++ b/.mock/definition/FileStorage/drives.yml @@ -7,7 +7,8 @@ service: list: path: /filestorage/v1/drives method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Drive` objects. pagination: cursor: $request.cursor @@ -74,7 +75,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -102,7 +113,8 @@ service: retrieve: path: /filestorage/v1/drives/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Drive` object with the given `id`. source: openapi: filestorage_v3.yml @@ -128,6 +140,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/FileStorage/fieldMapping.yml b/.mock/definition/FileStorage/fieldMapping.yml index 3875d4b78..34013d3a4 100644 --- a/.mock/definition/FileStorage/fieldMapping.yml +++ b/.mock/definition/FileStorage/fieldMapping.yml @@ -7,7 +7,8 @@ service: field_mappings_retrieve: path: /filestorage/v1/field-mappings method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge @@ -30,7 +31,9 @@ service: type: fileStorageRoot.FieldMappingApiInstanceResponse status-code: 200 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token response: body: @@ -117,7 +120,8 @@ service: field_mappings_create: path: /filestorage/v1/field-mappings method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to @@ -182,7 +186,9 @@ service: type: fileStorageRoot.FieldMappingInstanceResponse status-code: 201 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token request: target_field_name: example_target_field_name @@ -233,7 +239,8 @@ service: field_mappings_destroy: path: /filestorage/v1/field-mappings/{field_mapping_id} method: DELETE - auth: true + auth: + - tokenAuth: [] docs: >- Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after @@ -293,7 +300,8 @@ service: field_mappings_partial_update: path: /filestorage/v1/field-mappings/{field_mapping_id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: >- Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the @@ -377,7 +385,8 @@ service: remote_fields_retrieve: path: /filestorage/v1/remote-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data @@ -405,7 +414,10 @@ service: type: fileStorageRoot.RemoteFieldApiResponse status-code: 200 examples: - - headers: + - query-parameters: + common_models: common_models + include_example_values: include_example_values + headers: X-Account-Token: X-Account-Token response: body: @@ -482,7 +494,8 @@ service: target_fields_retrieve: path: /filestorage/v1/target-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields diff --git a/.mock/definition/FileStorage/files.yml b/.mock/definition/FileStorage/files.yml index 14a435fa0..ea98b7d93 100644 --- a/.mock/definition/FileStorage/files.yml +++ b/.mock/definition/FileStorage/files.yml @@ -46,7 +46,8 @@ service: list: path: /filestorage/v1/files method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `File` objects. pagination: cursor: $request.cursor @@ -140,7 +141,21 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + drive_id: drive_id + folder_id: folder_id + include_deleted_data: true + include_remote_data: true + include_shell_data: true + mime_type: mime_type + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + order_by: '-created_at' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -183,7 +198,8 @@ service: create: path: /filestorage/v1/files method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `File` object with the given values. source: openapi: filestorage_v3.yml @@ -207,7 +223,10 @@ service: type: fileStorageRoot.FileStorageFileResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -269,7 +288,8 @@ service: retrieve: path: /filestorage/v1/files/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `File` object with the given `id`. source: openapi: filestorage_v3.yml @@ -301,6 +321,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -340,7 +363,8 @@ service: downloadRetrieve: path: /filestorage/v1/files/{id}/download method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns the `File` content with the given `id` as a stream of bytes. source: openapi: filestorage_v3.yml @@ -369,7 +393,8 @@ service: downloadRequestMetaRetrieve: path: /filestorage/v1/files/{id}/download/request-meta method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns metadata to construct an authenticated file download request for a singular file, allowing you to download file directly from the @@ -396,6 +421,8 @@ service: examples: - path-parameters: id: id + query-parameters: + mime_type: mime_type headers: X-Account-Token: X-Account-Token response: @@ -408,7 +435,8 @@ service: downloadRequestMetaList: path: /filestorage/v1/files/download/request-meta method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns metadata to construct authenticated file download requests, allowing you to download files directly from the third-party. @@ -474,7 +502,15 @@ service: status-code: 200 examples: - query-parameters: + created_after: created_after + created_before: created_before cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + mime_types: mime_types + modified_after: modified_after + modified_before: modified_before + order_by: '-created_at' + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -490,7 +526,8 @@ service: metaPostRetrieve: path: /filestorage/v1/files/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `FileStorageFile` POSTs. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/folders.yml b/.mock/definition/FileStorage/folders.yml index 6faa2a609..c95cff0a6 100644 --- a/.mock/definition/FileStorage/folders.yml +++ b/.mock/definition/FileStorage/folders.yml @@ -22,7 +22,8 @@ service: list: path: /filestorage/v1/folders method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Folder` objects. pagination: cursor: $request.cursor @@ -103,7 +104,19 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + drive_id: drive_id + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + name: name + page_size: 1 + parent_folder_id: parent_folder_id + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -137,7 +150,8 @@ service: create: path: /filestorage/v1/folders method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Folder` object with the given values. source: openapi: filestorage_v3.yml @@ -161,7 +175,10 @@ service: type: fileStorageRoot.FileStorageFolderResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -214,7 +231,8 @@ service: retrieve: path: /filestorage/v1/folders/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Folder` object with the given `id`. source: openapi: filestorage_v3.yml @@ -246,6 +264,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -276,7 +297,8 @@ service: metaPostRetrieve: path: /filestorage/v1/folders/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `FileStorageFolder` POSTs. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/forceResync.yml b/.mock/definition/FileStorage/forceResync.yml index c19d7e52a..d280ccdf1 100644 --- a/.mock/definition/FileStorage/forceResync.yml +++ b/.mock/definition/FileStorage/forceResync.yml @@ -7,7 +7,8 @@ service: sync_status_resync_create: path: /filestorage/v1/sync-status/resync method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or diff --git a/.mock/definition/FileStorage/generateKey.yml b/.mock/definition/FileStorage/generateKey.yml index c7b20512e..4cc23f5ac 100644 --- a/.mock/definition/FileStorage/generateKey.yml +++ b/.mock/definition/FileStorage/generateKey.yml @@ -7,7 +7,8 @@ service: create: path: /filestorage/v1/generate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Create a remote key. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/groups.yml b/.mock/definition/FileStorage/groups.yml index e640c5bac..c7b80bf92 100644 --- a/.mock/definition/FileStorage/groups.yml +++ b/.mock/definition/FileStorage/groups.yml @@ -20,7 +20,8 @@ service: list: path: /filestorage/v1/groups method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Group` objects. pagination: cursor: $request.cursor @@ -88,7 +89,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -118,7 +128,8 @@ service: retrieve: path: /filestorage/v1/groups/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Group` object with the given `id`. source: openapi: filestorage_v3.yml @@ -150,6 +161,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/FileStorage/issues.yml b/.mock/definition/FileStorage/issues.yml index 782e99a1f..90fd8d722 100644 --- a/.mock/definition/FileStorage/issues.yml +++ b/.mock/definition/FileStorage/issues.yml @@ -14,7 +14,8 @@ service: list: path: /filestorage/v1/issues method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets all issues for Organization. pagination: cursor: $request.cursor @@ -85,7 +86,20 @@ service: status-code: 200 examples: - query-parameters: + account_token: account_token cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + end_user_organization_name: end_user_organization_name + first_incident_time_after: '2024-01-15T09:30:00Z' + first_incident_time_before: '2024-01-15T09:30:00Z' + include_muted: include_muted + integration_name: integration_name + last_incident_time_after: '2024-01-15T09:30:00Z' + last_incident_time_before: '2024-01-15T09:30:00Z' + linked_account_id: linked_account_id + page_size: 1 + start_date: start_date + status: ONGOING headers: X-Account-Token: '[object Object]' response: @@ -107,7 +121,8 @@ service: retrieve: path: /filestorage/v1/issues/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Get a specific issue. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/linkToken.yml b/.mock/definition/FileStorage/linkToken.yml index 44bec5baf..fedfc8940 100644 --- a/.mock/definition/FileStorage/linkToken.yml +++ b/.mock/definition/FileStorage/linkToken.yml @@ -24,7 +24,8 @@ service: create: path: /filestorage/v1/link-token method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a link token to be used when linking a new end user. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/linkedAccounts.yml b/.mock/definition/FileStorage/linkedAccounts.yml index 0cb268610..c74865ca0 100644 --- a/.mock/definition/FileStorage/linkedAccounts.yml +++ b/.mock/definition/FileStorage/linkedAccounts.yml @@ -19,7 +19,8 @@ service: list: path: /filestorage/v1/linked-accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: List linked accounts for your organization. pagination: cursor: $request.cursor @@ -112,7 +113,19 @@ service: status-code: 200 examples: - query-parameters: + category: accounting cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_user_email_address: end_user_email_address + end_user_organization_name: end_user_organization_name + end_user_origin_id: end_user_origin_id + end_user_origin_ids: end_user_origin_ids + id: id + ids: ids + include_duplicates: true + integration_name: integration_name + is_test_account: is_test_account + page_size: 1 + status: status headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/FileStorage/passthrough.yml b/.mock/definition/FileStorage/passthrough.yml index 6fe2b5d9f..9854d3a1d 100644 --- a/.mock/definition/FileStorage/passthrough.yml +++ b/.mock/definition/FileStorage/passthrough.yml @@ -7,7 +7,8 @@ service: create: path: /filestorage/v1/passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: Pull data from an endpoint not currently supported by Merge. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/regenerateKey.yml b/.mock/definition/FileStorage/regenerateKey.yml index fcdee8c11..e23e337c1 100644 --- a/.mock/definition/FileStorage/regenerateKey.yml +++ b/.mock/definition/FileStorage/regenerateKey.yml @@ -7,7 +7,8 @@ service: create: path: /filestorage/v1/regenerate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Exchange remote keys. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/FileStorage/scopes.yml b/.mock/definition/FileStorage/scopes.yml index b0148655a..49e604af9 100644 --- a/.mock/definition/FileStorage/scopes.yml +++ b/.mock/definition/FileStorage/scopes.yml @@ -7,7 +7,8 @@ service: default_scopes_retrieve: path: /filestorage/v1/default-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn @@ -50,7 +51,8 @@ service: linked_account_scopes_retrieve: path: /filestorage/v1/linked-account-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn @@ -93,7 +95,8 @@ service: linked_account_scopes_create: path: /filestorage/v1/linked-account-scopes method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the diff --git a/.mock/definition/FileStorage/syncStatus.yml b/.mock/definition/FileStorage/syncStatus.yml index 291662d18..ffa8a978c 100644 --- a/.mock/definition/FileStorage/syncStatus.yml +++ b/.mock/definition/FileStorage/syncStatus.yml @@ -7,7 +7,8 @@ service: list: path: /filestorage/v1/sync-status method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. @@ -42,6 +43,7 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/FileStorage/users.yml b/.mock/definition/FileStorage/users.yml index b7f6aefe4..9a388d309 100644 --- a/.mock/definition/FileStorage/users.yml +++ b/.mock/definition/FileStorage/users.yml @@ -7,7 +7,8 @@ service: list: path: /filestorage/v1/users method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `User` objects. pagination: cursor: $request.cursor @@ -72,7 +73,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_me: is_me + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -100,7 +111,8 @@ service: retrieve: path: /filestorage/v1/users/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `User` object with the given `id`. source: openapi: filestorage_v3.yml @@ -126,6 +138,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/FileStorage/webhookReceivers.yml b/.mock/definition/FileStorage/webhookReceivers.yml index d6d949440..fa7e6fd38 100644 --- a/.mock/definition/FileStorage/webhookReceivers.yml +++ b/.mock/definition/FileStorage/webhookReceivers.yml @@ -7,7 +7,8 @@ service: list: path: /filestorage/v1/webhook-receivers method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `WebhookReceiver` objects. source: openapi: filestorage_v3.yml @@ -26,7 +27,8 @@ service: create: path: /filestorage/v1/webhook-receivers method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `WebhookReceiver` object with the given values. source: openapi: filestorage_v3.yml diff --git a/.mock/definition/HRIS/accountDetails.yml b/.mock/definition/HRIS/accountDetails.yml index eb6c801f4..f392c0098 100644 --- a/.mock/definition/HRIS/accountDetails.yml +++ b/.mock/definition/HRIS/accountDetails.yml @@ -7,7 +7,8 @@ service: retrieve: path: /hris/v1/account-details method: GET - auth: true + auth: + - tokenAuth: [] docs: Get details for a linked account. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/accountToken.yml b/.mock/definition/HRIS/accountToken.yml index 823556e7f..7f9116bb0 100644 --- a/.mock/definition/HRIS/accountToken.yml +++ b/.mock/definition/HRIS/accountToken.yml @@ -7,7 +7,8 @@ service: retrieve: path: /hris/v1/account-token/{public_token} method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns the account token for the end user with the provided public token. diff --git a/.mock/definition/HRIS/asyncPassthrough.yml b/.mock/definition/HRIS/asyncPassthrough.yml index 2f745e1df..0b6a9ea34 100644 --- a/.mock/definition/HRIS/asyncPassthrough.yml +++ b/.mock/definition/HRIS/asyncPassthrough.yml @@ -7,7 +7,8 @@ service: create: path: /hris/v1/async-passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Asynchronously pull data from an endpoint not currently supported by Merge. @@ -32,7 +33,8 @@ service: retrieve: path: /hris/v1/async-passthrough/{async_passthrough_receipt_id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Retrieves data from earlier async-passthrough POST request source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/auditTrail.yml b/.mock/definition/HRIS/auditTrail.yml index f5d491d3e..49c27548e 100644 --- a/.mock/definition/HRIS/auditTrail.yml +++ b/.mock/definition/HRIS/auditTrail.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/audit-trail method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets a list of audit trail events. pagination: cursor: $request.cursor @@ -80,6 +81,11 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + event_type: event_type + page_size: 1 + start_date: start_date + user_email: user_email headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/HRIS/availableActions.yml b/.mock/definition/HRIS/availableActions.yml index 2bcd4ddb9..0d065d20d 100644 --- a/.mock/definition/HRIS/availableActions.yml +++ b/.mock/definition/HRIS/availableActions.yml @@ -7,7 +7,8 @@ service: retrieve: path: /hris/v1/available-actions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of models and actions available for an account. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/bankInfo.yml b/.mock/definition/HRIS/bankInfo.yml index d2fb4c10f..309396796 100644 --- a/.mock/definition/HRIS/bankInfo.yml +++ b/.mock/definition/HRIS/bankInfo.yml @@ -22,7 +22,8 @@ service: list: path: /hris/v1/bank-info method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `BankInfo` objects. pagination: cursor: $request.cursor @@ -121,7 +122,22 @@ service: status-code: 200 examples: - query-parameters: + account_type: CHECKING + bank_name: bank_name + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + employee_id: employee_id + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + order_by: '-remote_created_at' + page_size: 1 + remote_fields: account_type + remote_id: remote_id + show_enum_origins: account_type headers: X-Account-Token: X-Account-Token response: @@ -152,7 +168,8 @@ service: retrieve: path: /hris/v1/bank-info/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `BankInfo` object with the given `id`. source: openapi: hris_v3.yml @@ -194,6 +211,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: account_type + show_enum_origins: account_type headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/benefits.yml b/.mock/definition/HRIS/benefits.yml index 8400306fc..0d5618f24 100644 --- a/.mock/definition/HRIS/benefits.yml +++ b/.mock/definition/HRIS/benefits.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/benefits method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Benefit` objects. pagination: cursor: $request.cursor @@ -80,7 +81,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + employee_id: employee_id + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -112,7 +123,8 @@ service: retrieve: path: /hris/v1/benefits/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Benefit` object with the given `id`. source: openapi: hris_v3.yml @@ -144,6 +156,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/companies.yml b/.mock/definition/HRIS/companies.yml index 8e55842b2..f9025b094 100644 --- a/.mock/definition/HRIS/companies.yml +++ b/.mock/definition/HRIS/companies.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/companies method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Company` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -100,7 +110,8 @@ service: retrieve: path: /hris/v1/companies/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Company` object with the given `id`. source: openapi: hris_v3.yml @@ -126,6 +137,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/deleteAccount.yml b/.mock/definition/HRIS/deleteAccount.yml index a209a04ca..796d1449f 100644 --- a/.mock/definition/HRIS/deleteAccount.yml +++ b/.mock/definition/HRIS/deleteAccount.yml @@ -5,7 +5,8 @@ service: delete: path: /hris/v1/delete-account method: POST - auth: true + auth: + - tokenAuth: [] docs: Delete a linked account. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/dependents.yml b/.mock/definition/HRIS/dependents.yml index d3fab2e50..bdae82935 100644 --- a/.mock/definition/HRIS/dependents.yml +++ b/.mock/definition/HRIS/dependents.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/dependents method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Dependent` objects. pagination: cursor: $request.cursor @@ -74,7 +75,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_sensitive_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -110,7 +121,8 @@ service: retrieve: path: /hris/v1/dependents/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Dependent` object with the given `id`. source: openapi: hris_v3.yml @@ -141,6 +153,10 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_sensitive_fields: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/employeePayrollRuns.yml b/.mock/definition/HRIS/employeePayrollRuns.yml index f31b20cc1..e16eb5651 100644 --- a/.mock/definition/HRIS/employeePayrollRuns.yml +++ b/.mock/definition/HRIS/employeePayrollRuns.yml @@ -20,7 +20,8 @@ service: list: path: /hris/v1/employee-payroll-runs method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `EmployeePayrollRun` objects. pagination: cursor: $request.cursor @@ -118,7 +119,22 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + employee_id: employee_id + ended_after: '2024-01-15T09:30:00Z' + ended_before: '2024-01-15T09:30:00Z' + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + payroll_run_id: payroll_run_id + remote_id: remote_id + started_after: '2024-01-15T09:30:00Z' + started_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -179,7 +195,8 @@ service: retrieve: path: /hris/v1/employee-payroll-runs/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `EmployeePayrollRun` object with the given `id`. source: openapi: hris_v3.yml @@ -211,6 +228,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/employees.yml b/.mock/definition/HRIS/employees.yml index d8a7ab047..545cc55c2 100644 --- a/.mock/definition/HRIS/employees.yml +++ b/.mock/definition/HRIS/employees.yml @@ -159,7 +159,8 @@ service: list: path: /hris/v1/employees method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Employee` objects. pagination: cursor: $request.cursor @@ -326,7 +327,38 @@ service: status-code: 200 examples: - query-parameters: + company_id: company_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + display_full_name: display_full_name + employment_status: ACTIVE + employment_type: employment_type + first_name: first_name + groups: groups + home_location_id: home_location_id + include_deleted_data: true + include_remote_data: true + include_sensitive_fields: true + include_shell_data: true + job_title: job_title + last_name: last_name + manager_id: manager_id + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + pay_group_id: pay_group_id + personal_email: personal_email + remote_fields: employment_status + remote_id: remote_id + show_enum_origins: employment_status + started_after: '2024-01-15T09:30:00Z' + started_before: '2024-01-15T09:30:00Z' + team_id: team_id + terminated_after: '2024-01-15T09:30:00Z' + terminated_before: '2024-01-15T09:30:00Z' + work_email: work_email + work_location_id: work_location_id headers: X-Account-Token: X-Account-Token response: @@ -381,7 +413,8 @@ service: create: path: /hris/v1/employees method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Employee` object with the given values. source: openapi: hris_v3.yml @@ -405,7 +438,10 @@ service: type: hrisRoot.EmployeeResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -479,7 +515,8 @@ service: retrieve: path: /hris/v1/employees/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Employee` object with the given `id`. source: openapi: hris_v3.yml @@ -526,6 +563,12 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_sensitive_fields: true + include_shell_data: true + remote_fields: employment_status + show_enum_origins: employment_status headers: X-Account-Token: X-Account-Token response: @@ -577,7 +620,8 @@ service: ignoreCreate: path: /hris/v1/employees/ignore/{model_id} method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in @@ -600,7 +644,8 @@ service: metaPostRetrieve: path: /hris/v1/employees/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Employee` POSTs. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/employerBenefits.yml b/.mock/definition/HRIS/employerBenefits.yml index 8cc6c72eb..db54627de 100644 --- a/.mock/definition/HRIS/employerBenefits.yml +++ b/.mock/definition/HRIS/employerBenefits.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/employer-benefits method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `EmployerBenefit` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -96,7 +106,8 @@ service: retrieve: path: /hris/v1/employer-benefits/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `EmployerBenefit` object with the given `id`. source: openapi: hris_v3.yml @@ -122,6 +133,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/employments.yml b/.mock/definition/HRIS/employments.yml index 92b9a333e..4fdd65f29 100644 --- a/.mock/definition/HRIS/employments.yml +++ b/.mock/definition/HRIS/employments.yml @@ -148,7 +148,8 @@ service: list: path: /hris/v1/employments method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Employment` objects. pagination: cursor: $request.cursor @@ -234,7 +235,20 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + employee_id: employee_id + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + order_by: '-effective_date' + page_size: 1 + remote_fields: employment_type + remote_id: remote_id + show_enum_origins: employment_type headers: X-Account-Token: X-Account-Token response: @@ -269,7 +283,8 @@ service: retrieve: path: /hris/v1/employments/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Employment` object with the given `id`. source: openapi: hris_v3.yml @@ -311,6 +326,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: employment_type + show_enum_origins: employment_type headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/fieldMapping.yml b/.mock/definition/HRIS/fieldMapping.yml index e6a7333d8..995d6404c 100644 --- a/.mock/definition/HRIS/fieldMapping.yml +++ b/.mock/definition/HRIS/fieldMapping.yml @@ -7,7 +7,8 @@ service: field_mappings_retrieve: path: /hris/v1/field-mappings method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge @@ -30,7 +31,9 @@ service: type: hrisRoot.FieldMappingApiInstanceResponse status-code: 200 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token response: body: @@ -293,7 +296,8 @@ service: field_mappings_create: path: /hris/v1/field-mappings method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to @@ -358,7 +362,9 @@ service: type: hrisRoot.FieldMappingInstanceResponse status-code: 201 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token request: target_field_name: example_target_field_name @@ -409,7 +415,8 @@ service: field_mappings_destroy: path: /hris/v1/field-mappings/{field_mapping_id} method: DELETE - auth: true + auth: + - tokenAuth: [] docs: >- Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after @@ -469,7 +476,8 @@ service: field_mappings_partial_update: path: /hris/v1/field-mappings/{field_mapping_id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: >- Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the @@ -553,7 +561,8 @@ service: remote_fields_retrieve: path: /hris/v1/remote-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data @@ -581,7 +590,10 @@ service: type: hrisRoot.RemoteFieldApiResponse status-code: 200 examples: - - headers: + - query-parameters: + common_models: common_models + include_example_values: include_example_values + headers: X-Account-Token: X-Account-Token response: body: @@ -812,7 +824,8 @@ service: target_fields_retrieve: path: /hris/v1/target-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields diff --git a/.mock/definition/HRIS/forceResync.yml b/.mock/definition/HRIS/forceResync.yml index d4918920a..bd0a3857e 100644 --- a/.mock/definition/HRIS/forceResync.yml +++ b/.mock/definition/HRIS/forceResync.yml @@ -7,7 +7,8 @@ service: sync_status_resync_create: path: /hris/v1/sync-status/resync method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or diff --git a/.mock/definition/HRIS/generateKey.yml b/.mock/definition/HRIS/generateKey.yml index f22844cea..8cb621dbf 100644 --- a/.mock/definition/HRIS/generateKey.yml +++ b/.mock/definition/HRIS/generateKey.yml @@ -7,7 +7,8 @@ service: create: path: /hris/v1/generate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Create a remote key. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/groups.yml b/.mock/definition/HRIS/groups.yml index 1f67b8cd3..9693030f0 100644 --- a/.mock/definition/HRIS/groups.yml +++ b/.mock/definition/HRIS/groups.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/groups method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Group` objects. pagination: cursor: $request.cursor @@ -96,7 +97,21 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_commonly_used_as_team: is_commonly_used_as_team + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + names: names + page_size: 1 + remote_fields: type + remote_id: remote_id + show_enum_origins: type + types: types headers: X-Account-Token: X-Account-Token response: @@ -125,7 +140,8 @@ service: retrieve: path: /hris/v1/groups/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Group` object with the given `id`. source: openapi: hris_v3.yml @@ -161,6 +177,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: type + show_enum_origins: type headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/issues.yml b/.mock/definition/HRIS/issues.yml index 1ecee14ab..fb74883d4 100644 --- a/.mock/definition/HRIS/issues.yml +++ b/.mock/definition/HRIS/issues.yml @@ -14,7 +14,8 @@ service: list: path: /hris/v1/issues method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets all issues for Organization. pagination: cursor: $request.cursor @@ -85,7 +86,20 @@ service: status-code: 200 examples: - query-parameters: + account_token: account_token cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + end_user_organization_name: end_user_organization_name + first_incident_time_after: '2024-01-15T09:30:00Z' + first_incident_time_before: '2024-01-15T09:30:00Z' + include_muted: include_muted + integration_name: integration_name + last_incident_time_after: '2024-01-15T09:30:00Z' + last_incident_time_before: '2024-01-15T09:30:00Z' + linked_account_id: linked_account_id + page_size: 1 + start_date: start_date + status: ONGOING headers: X-Account-Token: '[object Object]' response: @@ -107,7 +121,8 @@ service: retrieve: path: /hris/v1/issues/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Get a specific issue. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/linkToken.yml b/.mock/definition/HRIS/linkToken.yml index a8b52f548..f589adda2 100644 --- a/.mock/definition/HRIS/linkToken.yml +++ b/.mock/definition/HRIS/linkToken.yml @@ -24,7 +24,8 @@ service: create: path: /hris/v1/link-token method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a link token to be used when linking a new end user. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/linkedAccounts.yml b/.mock/definition/HRIS/linkedAccounts.yml index a74312d19..a5afc183a 100644 --- a/.mock/definition/HRIS/linkedAccounts.yml +++ b/.mock/definition/HRIS/linkedAccounts.yml @@ -19,7 +19,8 @@ service: list: path: /hris/v1/linked-accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: List linked accounts for your organization. pagination: cursor: $request.cursor @@ -112,7 +113,19 @@ service: status-code: 200 examples: - query-parameters: + category: accounting cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_user_email_address: end_user_email_address + end_user_organization_name: end_user_organization_name + end_user_origin_id: end_user_origin_id + end_user_origin_ids: end_user_origin_ids + id: id + ids: ids + include_duplicates: true + integration_name: integration_name + is_test_account: is_test_account + page_size: 1 + status: status headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/HRIS/locations.yml b/.mock/definition/HRIS/locations.yml index 4c5da26e9..58bafc923 100644 --- a/.mock/definition/HRIS/locations.yml +++ b/.mock/definition/HRIS/locations.yml @@ -46,7 +46,8 @@ service: list: path: /hris/v1/locations method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Location` objects. pagination: cursor: $request.cursor @@ -125,7 +126,19 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + location_type: HOME + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: country + remote_id: remote_id + show_enum_origins: country headers: X-Account-Token: X-Account-Token response: @@ -159,7 +172,8 @@ service: retrieve: path: /hris/v1/locations/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Location` object with the given `id`. source: openapi: hris_v3.yml @@ -195,6 +209,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: country + show_enum_origins: country headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/passthrough.yml b/.mock/definition/HRIS/passthrough.yml index 5b1cabb97..d3e6c8607 100644 --- a/.mock/definition/HRIS/passthrough.yml +++ b/.mock/definition/HRIS/passthrough.yml @@ -7,7 +7,8 @@ service: create: path: /hris/v1/passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: Pull data from an endpoint not currently supported by Merge. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/payGroups.yml b/.mock/definition/HRIS/payGroups.yml index 5cb7746df..25fa26504 100644 --- a/.mock/definition/HRIS/payGroups.yml +++ b/.mock/definition/HRIS/payGroups.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/pay-groups method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `PayGroup` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -95,7 +105,8 @@ service: retrieve: path: /hris/v1/pay-groups/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `PayGroup` object with the given `id`. source: openapi: hris_v3.yml @@ -121,6 +132,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/payrollRuns.yml b/.mock/definition/HRIS/payrollRuns.yml index a79bc9e33..2ee23ce83 100644 --- a/.mock/definition/HRIS/payrollRuns.yml +++ b/.mock/definition/HRIS/payrollRuns.yml @@ -49,7 +49,8 @@ service: list: path: /hris/v1/payroll-runs method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `PayrollRun` objects. pagination: cursor: $request.cursor @@ -158,7 +159,23 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + ended_after: '2024-01-15T09:30:00Z' + ended_before: '2024-01-15T09:30:00Z' + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: run_state + remote_id: remote_id + run_type: CORRECTION + show_enum_origins: run_state + started_after: '2024-01-15T09:30:00Z' + started_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -188,7 +205,8 @@ service: retrieve: path: /hris/v1/payroll-runs/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `PayrollRun` object with the given `id`. source: openapi: hris_v3.yml @@ -224,6 +242,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: run_state + show_enum_origins: run_state headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/regenerateKey.yml b/.mock/definition/HRIS/regenerateKey.yml index a6f3ceac4..041f97c44 100644 --- a/.mock/definition/HRIS/regenerateKey.yml +++ b/.mock/definition/HRIS/regenerateKey.yml @@ -7,7 +7,8 @@ service: create: path: /hris/v1/regenerate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Exchange remote keys. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/scopes.yml b/.mock/definition/HRIS/scopes.yml index c7b39fa72..24139c3f3 100644 --- a/.mock/definition/HRIS/scopes.yml +++ b/.mock/definition/HRIS/scopes.yml @@ -7,7 +7,8 @@ service: default_scopes_retrieve: path: /hris/v1/default-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn @@ -50,7 +51,8 @@ service: linked_account_scopes_retrieve: path: /hris/v1/linked-account-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn @@ -93,7 +95,8 @@ service: linked_account_scopes_create: path: /hris/v1/linked-account-scopes method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the diff --git a/.mock/definition/HRIS/syncStatus.yml b/.mock/definition/HRIS/syncStatus.yml index 90db422cb..8f676be29 100644 --- a/.mock/definition/HRIS/syncStatus.yml +++ b/.mock/definition/HRIS/syncStatus.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/sync-status method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. @@ -42,6 +43,7 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/teams.yml b/.mock/definition/HRIS/teams.yml index 29ed6fe72..fce94aed9 100644 --- a/.mock/definition/HRIS/teams.yml +++ b/.mock/definition/HRIS/teams.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/teams method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Team` objects. pagination: cursor: $request.cursor @@ -78,7 +79,17 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + parent_team_id: parent_team_id + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -105,7 +116,8 @@ service: retrieve: path: /hris/v1/teams/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Team` object with the given `id`. source: openapi: hris_v3.yml @@ -137,6 +149,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/timeOff.yml b/.mock/definition/HRIS/timeOff.yml index 40bc6b1ea..4b024ba98 100644 --- a/.mock/definition/HRIS/timeOff.yml +++ b/.mock/definition/HRIS/timeOff.yml @@ -99,7 +99,8 @@ service: list: path: /hris/v1/time-off method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `TimeOff` objects. pagination: cursor: $request.cursor @@ -238,7 +239,26 @@ service: status-code: 200 examples: - query-parameters: + approver_id: approver_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + employee_id: employee_id + ended_after: '2024-01-15T09:30:00Z' + ended_before: '2024-01-15T09:30:00Z' + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_fields: request_type + remote_id: remote_id + request_type: BEREAVEMENT + show_enum_origins: request_type + started_after: '2024-01-15T09:30:00Z' + started_before: '2024-01-15T09:30:00Z' + status: APPROVED headers: X-Account-Token: X-Account-Token response: @@ -272,7 +292,8 @@ service: create: path: /hris/v1/time-off method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `TimeOff` object with the given values. source: openapi: hris_v3.yml @@ -296,7 +317,10 @@ service: type: hrisRoot.TimeOffResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -349,7 +373,8 @@ service: retrieve: path: /hris/v1/time-off/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `TimeOff` object with the given `id`. source: openapi: hris_v3.yml @@ -391,6 +416,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: request_type + show_enum_origins: request_type headers: X-Account-Token: X-Account-Token response: @@ -421,7 +451,8 @@ service: metaPostRetrieve: path: /hris/v1/time-off/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `TimeOff` POSTs. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/timeOffBalances.yml b/.mock/definition/HRIS/timeOffBalances.yml index e9e5650c7..0fec21a1c 100644 --- a/.mock/definition/HRIS/timeOffBalances.yml +++ b/.mock/definition/HRIS/timeOffBalances.yml @@ -18,7 +18,8 @@ service: list: path: /hris/v1/time-off-balances method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `TimeOffBalance` objects. pagination: cursor: $request.cursor @@ -118,7 +119,20 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + employee_id: employee_id + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + policy_type: BEREAVEMENT + remote_fields: policy_type + remote_id: remote_id + show_enum_origins: policy_type headers: X-Account-Token: X-Account-Token response: @@ -147,7 +161,8 @@ service: retrieve: path: /hris/v1/time-off-balances/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `TimeOffBalance` object with the given `id`. source: openapi: hris_v3.yml @@ -189,6 +204,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: policy_type + show_enum_origins: policy_type headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/HRIS/timesheetEntries.yml b/.mock/definition/HRIS/timesheetEntries.yml index 100580994..6c7fb8335 100644 --- a/.mock/definition/HRIS/timesheetEntries.yml +++ b/.mock/definition/HRIS/timesheetEntries.yml @@ -16,7 +16,8 @@ service: list: path: /hris/v1/timesheet-entries method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `TimesheetEntry` objects. pagination: cursor: $request.cursor @@ -112,7 +113,22 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + employee_id: employee_id + ended_after: '2024-01-15T09:30:00Z' + ended_before: '2024-01-15T09:30:00Z' + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + order_by: '-start_time' + page_size: 1 + remote_id: remote_id + started_after: '2024-01-15T09:30:00Z' + started_before: '2024-01-15T09:30:00Z' headers: X-Account-Token: X-Account-Token response: @@ -141,7 +157,8 @@ service: create: path: /hris/v1/timesheet-entries method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `TimesheetEntry` object with the given values. source: openapi: hris_v3.yml @@ -165,7 +182,10 @@ service: type: hrisRoot.TimesheetEntryResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -213,7 +233,8 @@ service: retrieve: path: /hris/v1/timesheet-entries/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `TimesheetEntry` object with the given `id`. source: openapi: hris_v3.yml @@ -245,6 +266,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -270,7 +294,8 @@ service: metaPostRetrieve: path: /hris/v1/timesheet-entries/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `TimesheetEntry` POSTs. source: openapi: hris_v3.yml diff --git a/.mock/definition/HRIS/webhookReceivers.yml b/.mock/definition/HRIS/webhookReceivers.yml index 11e213981..3bc0cc7d8 100644 --- a/.mock/definition/HRIS/webhookReceivers.yml +++ b/.mock/definition/HRIS/webhookReceivers.yml @@ -7,7 +7,8 @@ service: list: path: /hris/v1/webhook-receivers method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `WebhookReceiver` objects. source: openapi: hris_v3.yml @@ -26,7 +27,8 @@ service: create: path: /hris/v1/webhook-receivers method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `WebhookReceiver` object with the given values. source: openapi: hris_v3.yml diff --git a/.mock/definition/Ticketing/accountDetails.yml b/.mock/definition/Ticketing/accountDetails.yml index cbd87fb9a..b5b6bd417 100644 --- a/.mock/definition/Ticketing/accountDetails.yml +++ b/.mock/definition/Ticketing/accountDetails.yml @@ -7,7 +7,8 @@ service: retrieve: path: /ticketing/v1/account-details method: GET - auth: true + auth: + - tokenAuth: [] docs: Get details for a linked account. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/accountToken.yml b/.mock/definition/Ticketing/accountToken.yml index bc7ab15fb..2f2e9e091 100644 --- a/.mock/definition/Ticketing/accountToken.yml +++ b/.mock/definition/Ticketing/accountToken.yml @@ -7,7 +7,8 @@ service: retrieve: path: /ticketing/v1/account-token/{public_token} method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns the account token for the end user with the provided public token. diff --git a/.mock/definition/Ticketing/accounts.yml b/.mock/definition/Ticketing/accounts.yml index 1d93c29ee..f27dbee0c 100644 --- a/.mock/definition/Ticketing/accounts.yml +++ b/.mock/definition/Ticketing/accounts.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Account` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -98,7 +108,8 @@ service: retrieve: path: /ticketing/v1/accounts/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Account` object with the given `id`. source: openapi: ticketing_v3.yml @@ -124,6 +135,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/asyncPassthrough.yml b/.mock/definition/Ticketing/asyncPassthrough.yml index 9a26bc2db..7f570a7e6 100644 --- a/.mock/definition/Ticketing/asyncPassthrough.yml +++ b/.mock/definition/Ticketing/asyncPassthrough.yml @@ -7,7 +7,8 @@ service: create: path: /ticketing/v1/async-passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Asynchronously pull data from an endpoint not currently supported by Merge. @@ -32,7 +33,8 @@ service: retrieve: path: /ticketing/v1/async-passthrough/{async_passthrough_receipt_id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Retrieves data from earlier async-passthrough POST request source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/attachments.yml b/.mock/definition/Ticketing/attachments.yml index 776fcb117..e1c9d0dfd 100644 --- a/.mock/definition/Ticketing/attachments.yml +++ b/.mock/definition/Ticketing/attachments.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/attachments method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Attachment` objects. pagination: cursor: $request.cursor @@ -83,7 +84,18 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_created_after: '2024-01-15T09:30:00Z' + remote_id: remote_id + ticket_id: ticket_id headers: X-Account-Token: X-Account-Token response: @@ -112,7 +124,8 @@ service: create: path: /ticketing/v1/attachments method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates an `Attachment` object with the given values. source: openapi: ticketing_v3.yml @@ -136,7 +149,10 @@ service: type: ticketingRoot.TicketingAttachmentResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -184,7 +200,8 @@ service: retrieve: path: /ticketing/v1/attachments/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns an `Attachment` object with the given `id`. source: openapi: ticketing_v3.yml @@ -216,6 +233,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -243,7 +263,8 @@ service: downloadRetrieve: path: /ticketing/v1/attachments/{id}/download method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns the `File` content with the given `id` as a stream of bytes. source: openapi: ticketing_v3.yml @@ -272,7 +293,8 @@ service: metaPostRetrieve: path: /ticketing/v1/attachments/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `TicketingAttachment` POSTs. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/auditTrail.yml b/.mock/definition/Ticketing/auditTrail.yml index 1ac61ff27..bbc472c92 100644 --- a/.mock/definition/Ticketing/auditTrail.yml +++ b/.mock/definition/Ticketing/auditTrail.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/audit-trail method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets a list of audit trail events. pagination: cursor: $request.cursor @@ -81,6 +82,11 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + event_type: event_type + page_size: 1 + start_date: start_date + user_email: user_email headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/Ticketing/availableActions.yml b/.mock/definition/Ticketing/availableActions.yml index 1133adafc..a29cc9c8b 100644 --- a/.mock/definition/Ticketing/availableActions.yml +++ b/.mock/definition/Ticketing/availableActions.yml @@ -7,7 +7,8 @@ service: retrieve: path: /ticketing/v1/available-actions method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of models and actions available for an account. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/collections.yml b/.mock/definition/Ticketing/collections.yml index 3d47804c5..a128befc2 100644 --- a/.mock/definition/Ticketing/collections.yml +++ b/.mock/definition/Ticketing/collections.yml @@ -1,3 +1,18 @@ +types: + CollectionsListRequestCollectionType: + enum: + - value: '' + name: EMPTY + - LIST + - PROJECT + source: + openapi: ticketing_v3.yml + CollectionsViewersListRequestExpandItem: + enum: + - team + - user + source: + openapi: ticketing_v3.yml imports: ticketingRoot: __package__.yml service: @@ -7,7 +22,8 @@ service: list: path: /ticketing/v1/collections method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Collection` objects. pagination: cursor: $request.cursor @@ -19,7 +35,7 @@ service: name: CollectionsListRequest query-parameters: collection_type: - type: optional + type: optional docs: If provided, will only return collections of the given type. created_after: type: optional @@ -93,7 +109,20 @@ service: status-code: 200 examples: - query-parameters: + collection_type: '' + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + parent_collection_id: parent_collection_id + remote_fields: collection_type + remote_id: remote_id + show_enum_origins: collection_type headers: X-Account-Token: X-Account-Token response: @@ -121,7 +150,8 @@ service: viewersList: path: /ticketing/v1/collections/{collection_id}/viewers method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns a list of `Viewer` objects that point to a User id or Team id that is either an assignee or viewer on a `Collection` with the given @@ -177,6 +207,10 @@ service: collection_id: collection_id query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -193,7 +227,8 @@ service: retrieve: path: /ticketing/v1/collections/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Collection` object with the given `id`. source: openapi: ticketing_v3.yml @@ -235,6 +270,11 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true + remote_fields: collection_type + show_enum_origins: collection_type headers: X-Account-Token: X-Account-Token response: @@ -260,10 +300,3 @@ service: key: value source: openapi: ticketing_v3.yml -types: - CollectionsViewersListRequestExpandItem: - enum: - - team - - user - source: - openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/comments.yml b/.mock/definition/Ticketing/comments.yml index a252d5dd9..a7024c5f6 100644 --- a/.mock/definition/Ticketing/comments.yml +++ b/.mock/definition/Ticketing/comments.yml @@ -22,7 +22,8 @@ service: list: path: /ticketing/v1/comments method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Comment` objects. pagination: cursor: $request.cursor @@ -98,7 +99,18 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_created_after: '2024-01-15T09:30:00Z' + remote_id: remote_id + ticket_id: ticket_id headers: X-Account-Token: X-Account-Token response: @@ -132,7 +144,8 @@ service: create: path: /ticketing/v1/comments method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Comment` object with the given values. source: openapi: ticketing_v3.yml @@ -156,7 +169,10 @@ service: type: ticketingRoot.CommentResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -209,7 +225,8 @@ service: retrieve: path: /ticketing/v1/comments/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Comment` object with the given `id`. source: openapi: ticketing_v3.yml @@ -241,6 +258,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -271,7 +291,8 @@ service: metaPostRetrieve: path: /ticketing/v1/comments/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Comment` POSTs. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/contacts.yml b/.mock/definition/Ticketing/contacts.yml index 56fd54e5d..4e68f3610 100644 --- a/.mock/definition/Ticketing/contacts.yml +++ b/.mock/definition/Ticketing/contacts.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/contacts method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Contact` objects. pagination: cursor: $request.cursor @@ -75,7 +76,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -103,7 +113,8 @@ service: create: path: /ticketing/v1/contacts method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Contact` object with the given values. source: openapi: ticketing_v3.yml @@ -127,7 +138,10 @@ service: type: ticketingRoot.TicketingContactResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -174,7 +188,8 @@ service: retrieve: path: /ticketing/v1/contacts/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Contact` object with the given `id`. source: openapi: ticketing_v3.yml @@ -206,6 +221,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -232,7 +250,8 @@ service: metaPostRetrieve: path: /ticketing/v1/contacts/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `TicketingContact` POSTs. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/deleteAccount.yml b/.mock/definition/Ticketing/deleteAccount.yml index e166b7194..bb3fabec6 100644 --- a/.mock/definition/Ticketing/deleteAccount.yml +++ b/.mock/definition/Ticketing/deleteAccount.yml @@ -5,7 +5,8 @@ service: delete: path: /ticketing/v1/delete-account method: POST - auth: true + auth: + - tokenAuth: [] docs: Delete a linked account. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/fieldMapping.yml b/.mock/definition/Ticketing/fieldMapping.yml index 1f26ea6df..3bbc3da4d 100644 --- a/.mock/definition/Ticketing/fieldMapping.yml +++ b/.mock/definition/Ticketing/fieldMapping.yml @@ -7,7 +7,8 @@ service: field_mappings_retrieve: path: /ticketing/v1/field-mappings method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge @@ -30,7 +31,9 @@ service: type: ticketingRoot.FieldMappingApiInstanceResponse status-code: 200 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token response: body: @@ -213,7 +216,8 @@ service: field_mappings_create: path: /ticketing/v1/field-mappings method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to @@ -278,7 +282,9 @@ service: type: ticketingRoot.FieldMappingInstanceResponse status-code: 201 examples: - - headers: + - query-parameters: + exclude_remote_field_metadata: true + headers: X-Account-Token: X-Account-Token request: target_field_name: example_target_field_name @@ -329,7 +335,8 @@ service: field_mappings_destroy: path: /ticketing/v1/field-mappings/{field_mapping_id} method: DELETE - auth: true + auth: + - tokenAuth: [] docs: >- Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after @@ -389,7 +396,8 @@ service: field_mappings_partial_update: path: /ticketing/v1/field-mappings/{field_mapping_id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: >- Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the @@ -473,7 +481,8 @@ service: remote_fields_retrieve: path: /ticketing/v1/remote-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data @@ -501,7 +510,10 @@ service: type: ticketingRoot.RemoteFieldApiResponse status-code: 200 examples: - - headers: + - query-parameters: + common_models: common_models + include_example_values: include_example_values + headers: X-Account-Token: X-Account-Token response: body: @@ -662,7 +674,8 @@ service: target_fields_retrieve: path: /ticketing/v1/target-fields method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields diff --git a/.mock/definition/Ticketing/forceResync.yml b/.mock/definition/Ticketing/forceResync.yml index 96c6e0f5e..9e91fd2d1 100644 --- a/.mock/definition/Ticketing/forceResync.yml +++ b/.mock/definition/Ticketing/forceResync.yml @@ -7,7 +7,8 @@ service: sync_status_resync_create: path: /ticketing/v1/sync-status/resync method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or diff --git a/.mock/definition/Ticketing/generateKey.yml b/.mock/definition/Ticketing/generateKey.yml index 4869e4ff4..7e6164a84 100644 --- a/.mock/definition/Ticketing/generateKey.yml +++ b/.mock/definition/Ticketing/generateKey.yml @@ -7,7 +7,8 @@ service: create: path: /ticketing/v1/generate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Create a remote key. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/issues.yml b/.mock/definition/Ticketing/issues.yml index b096c2eb1..dbeaa54d9 100644 --- a/.mock/definition/Ticketing/issues.yml +++ b/.mock/definition/Ticketing/issues.yml @@ -14,7 +14,8 @@ service: list: path: /ticketing/v1/issues method: GET - auth: true + auth: + - tokenAuth: [] docs: Gets all issues for Organization. pagination: cursor: $request.cursor @@ -85,7 +86,20 @@ service: status-code: 200 examples: - query-parameters: + account_token: account_token cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_date: end_date + end_user_organization_name: end_user_organization_name + first_incident_time_after: '2024-01-15T09:30:00Z' + first_incident_time_before: '2024-01-15T09:30:00Z' + include_muted: include_muted + integration_name: integration_name + last_incident_time_after: '2024-01-15T09:30:00Z' + last_incident_time_before: '2024-01-15T09:30:00Z' + linked_account_id: linked_account_id + page_size: 1 + start_date: start_date + status: ONGOING headers: X-Account-Token: '[object Object]' response: @@ -107,7 +121,8 @@ service: retrieve: path: /ticketing/v1/issues/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Get a specific issue. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/linkToken.yml b/.mock/definition/Ticketing/linkToken.yml index 8fdf47bd9..90f0862fd 100644 --- a/.mock/definition/Ticketing/linkToken.yml +++ b/.mock/definition/Ticketing/linkToken.yml @@ -24,7 +24,8 @@ service: create: path: /ticketing/v1/link-token method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a link token to be used when linking a new end user. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/linkedAccounts.yml b/.mock/definition/Ticketing/linkedAccounts.yml index d426f3ffc..f4d447469 100644 --- a/.mock/definition/Ticketing/linkedAccounts.yml +++ b/.mock/definition/Ticketing/linkedAccounts.yml @@ -19,7 +19,8 @@ service: list: path: /ticketing/v1/linked-accounts method: GET - auth: true + auth: + - tokenAuth: [] docs: List linked accounts for your organization. pagination: cursor: $request.cursor @@ -112,7 +113,19 @@ service: status-code: 200 examples: - query-parameters: + category: accounting cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + end_user_email_address: end_user_email_address + end_user_organization_name: end_user_organization_name + end_user_origin_id: end_user_origin_id + end_user_origin_ids: end_user_origin_ids + id: id + ids: ids + include_duplicates: true + integration_name: integration_name + is_test_account: is_test_account + page_size: 1 + status: status headers: X-Account-Token: '[object Object]' response: diff --git a/.mock/definition/Ticketing/passthrough.yml b/.mock/definition/Ticketing/passthrough.yml index 47622b6d6..c0968fafe 100644 --- a/.mock/definition/Ticketing/passthrough.yml +++ b/.mock/definition/Ticketing/passthrough.yml @@ -7,7 +7,8 @@ service: create: path: /ticketing/v1/passthrough method: POST - auth: true + auth: + - tokenAuth: [] docs: Pull data from an endpoint not currently supported by Merge. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/projects.yml b/.mock/definition/Ticketing/projects.yml index e1560c7f8..8920b177e 100644 --- a/.mock/definition/Ticketing/projects.yml +++ b/.mock/definition/Ticketing/projects.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/projects method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Project` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -94,7 +104,8 @@ service: retrieve: path: /ticketing/v1/projects/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Project` object with the given `id`. source: openapi: ticketing_v3.yml @@ -120,6 +131,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: @@ -143,7 +157,8 @@ service: usersList: path: /ticketing/v1/projects/{parent_id}/users method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `User` objects. pagination: cursor: $request.cursor @@ -195,6 +210,10 @@ service: parent_id: parent_id query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/regenerateKey.yml b/.mock/definition/Ticketing/regenerateKey.yml index d7973bbf0..054c3dc1c 100644 --- a/.mock/definition/Ticketing/regenerateKey.yml +++ b/.mock/definition/Ticketing/regenerateKey.yml @@ -7,7 +7,8 @@ service: create: path: /ticketing/v1/regenerate-key method: POST - auth: true + auth: + - tokenAuth: [] docs: Exchange remote keys. source: openapi: ticketing_v3.yml diff --git a/.mock/definition/Ticketing/roles.yml b/.mock/definition/Ticketing/roles.yml index e541cfc88..3067049b8 100644 --- a/.mock/definition/Ticketing/roles.yml +++ b/.mock/definition/Ticketing/roles.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/roles method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Role` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -98,7 +108,8 @@ service: retrieve: path: /ticketing/v1/roles/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Role` object with the given `id`. source: openapi: ticketing_v3.yml @@ -124,6 +135,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/scopes.yml b/.mock/definition/Ticketing/scopes.yml index 573d010e1..82bf8e0e8 100644 --- a/.mock/definition/Ticketing/scopes.yml +++ b/.mock/definition/Ticketing/scopes.yml @@ -7,7 +7,8 @@ service: default_scopes_retrieve: path: /ticketing/v1/default-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn @@ -50,7 +51,8 @@ service: linked_account_scopes_retrieve: path: /ticketing/v1/linked-account-scopes method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn @@ -93,7 +95,8 @@ service: linked_account_scopes_create: path: /ticketing/v1/linked-account-scopes method: POST - auth: true + auth: + - tokenAuth: [] docs: >- Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the diff --git a/.mock/definition/Ticketing/syncStatus.yml b/.mock/definition/Ticketing/syncStatus.yml index 069c60cf0..335739ba2 100644 --- a/.mock/definition/Ticketing/syncStatus.yml +++ b/.mock/definition/Ticketing/syncStatus.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/sync-status method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. @@ -42,6 +43,7 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/tags.yml b/.mock/definition/Ticketing/tags.yml index b8f113868..69e5f0434 100644 --- a/.mock/definition/Ticketing/tags.yml +++ b/.mock/definition/Ticketing/tags.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/tags method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Tag` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -93,7 +103,8 @@ service: retrieve: path: /ticketing/v1/tags/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Tag` object with the given `id`. source: openapi: ticketing_v3.yml @@ -119,6 +130,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/teams.yml b/.mock/definition/Ticketing/teams.yml index ecba7d291..9654bf8a4 100644 --- a/.mock/definition/Ticketing/teams.yml +++ b/.mock/definition/Ticketing/teams.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/teams method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Team` objects. pagination: cursor: $request.cursor @@ -69,7 +70,16 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id headers: X-Account-Token: X-Account-Token response: @@ -94,7 +104,8 @@ service: retrieve: path: /ticketing/v1/teams/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Team` object with the given `id`. source: openapi: ticketing_v3.yml @@ -120,6 +131,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/tickets.yml b/.mock/definition/Ticketing/tickets.yml index 3ae1d3605..e2586ca8a 100644 --- a/.mock/definition/Ticketing/tickets.yml +++ b/.mock/definition/Ticketing/tickets.yml @@ -49,6 +49,16 @@ types: - ticket_type source: openapi: ticketing_v3.yml + TicketsListRequestStatus: + enum: + - value: '' + name: EMPTY + - CLOSED + - IN_PROGRESS + - ON_HOLD + - OPEN + source: + openapi: ticketing_v3.yml TicketsRetrieveRequestExpandItem: enum: - account @@ -106,7 +116,8 @@ service: list: path: /ticketing/v1/tickets method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `Ticket` objects. pagination: cursor: $request.cursor @@ -252,7 +263,7 @@ service: enum values. [Learn more](https://help.merge.dev/en/articles/8950958-show_enum_origins-query-parameter) status: - type: optional + type: optional docs: If provided, will only return tickets of this status. tags: type: optional @@ -275,7 +286,38 @@ service: status-code: 200 examples: - query-parameters: + account_id: account_id + assignee_ids: assignee_ids + collection_ids: collection_ids + completed_after: '2024-01-15T09:30:00Z' + completed_before: '2024-01-15T09:30:00Z' + contact_id: contact_id + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' + creator_id: creator_id cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + due_after: '2024-01-15T09:30:00Z' + due_before: '2024-01-15T09:30:00Z' + include_deleted_data: true + include_remote_data: true + include_remote_fields: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + parent_ticket_id: parent_ticket_id + priority: HIGH + remote_created_after: '2024-01-15T09:30:00Z' + remote_created_before: '2024-01-15T09:30:00Z' + remote_fields: priority + remote_id: remote_id + remote_updated_after: '2024-01-15T09:30:00Z' + remote_updated_before: '2024-01-15T09:30:00Z' + show_enum_origins: priority + status: '' + tags: tags + ticket_type: ticket_type + ticket_url: ticket_url headers: X-Account-Token: X-Account-Token response: @@ -332,7 +374,8 @@ service: create: path: /ticketing/v1/tickets method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `Ticket` object with the given values. source: openapi: ticketing_v3.yml @@ -356,7 +399,10 @@ service: type: ticketingRoot.TicketResponse status-code: 201 examples: - - headers: + - query-parameters: + is_debug_mode: true + run_async: true + headers: X-Account-Token: X-Account-Token request: model: {} @@ -432,7 +478,8 @@ service: retrieve: path: /ticketing/v1/tickets/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `Ticket` object with the given `id`. source: openapi: ticketing_v3.yml @@ -479,6 +526,12 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_remote_fields: true + include_shell_data: true + remote_fields: priority + show_enum_origins: priority headers: X-Account-Token: X-Account-Token response: @@ -536,7 +589,8 @@ service: partialUpdate: path: /ticketing/v1/tickets/{id} method: PATCH - auth: true + auth: + - tokenAuth: [] docs: Updates a `Ticket` object with the given `id`. source: openapi: ticketing_v3.yml @@ -564,6 +618,9 @@ service: examples: - path-parameters: id: id + query-parameters: + is_debug_mode: true + run_async: true headers: X-Account-Token: X-Account-Token request: @@ -640,7 +697,8 @@ service: viewersList: path: /ticketing/v1/tickets/{ticket_id}/viewers method: GET - auth: true + auth: + - tokenAuth: [] docs: >- Returns a list of `Viewer` objects that point to a User id or Team id that is either an assignee or viewer on a `Ticket` with the given id. @@ -696,6 +754,10 @@ service: ticket_id: ticket_id query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + include_deleted_data: true + include_remote_data: true + include_shell_data: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: @@ -712,7 +774,8 @@ service: metaPatchRetrieve: path: /ticketing/v1/tickets/meta/patch/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Ticket` PATCHs. source: openapi: ticketing_v3.yml @@ -901,7 +964,8 @@ service: metaPostRetrieve: path: /ticketing/v1/tickets/meta/post method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns metadata for `Ticket` POSTs. source: openapi: ticketing_v3.yml @@ -919,7 +983,10 @@ service: type: ticketingRoot.MetaResponse status-code: 200 examples: - - headers: + - query-parameters: + collection_id: collection_id + ticket_type: ticket_type + headers: X-Account-Token: X-Account-Token response: body: @@ -1095,7 +1162,8 @@ service: remoteFieldClassesList: path: /ticketing/v1/tickets/remote-field-classes method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `RemoteFieldClass` objects. pagination: cursor: $request.cursor @@ -1152,6 +1220,13 @@ service: examples: - query-parameters: cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + ids: ids + include_deleted_data: true + include_remote_data: true + include_shell_data: true + is_common_model_field: true + is_custom: true + page_size: 1 headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/users.yml b/.mock/definition/Ticketing/users.yml index bff6a9375..8ab9181ef 100644 --- a/.mock/definition/Ticketing/users.yml +++ b/.mock/definition/Ticketing/users.yml @@ -20,7 +20,8 @@ service: list: path: /ticketing/v1/users method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `User` objects. pagination: cursor: $request.cursor @@ -96,7 +97,18 @@ service: status-code: 200 examples: - query-parameters: + created_after: '2024-01-15T09:30:00Z' + created_before: '2024-01-15T09:30:00Z' cursor: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + email_address: email_address + include_deleted_data: true + include_remote_data: true + include_shell_data: true + modified_after: '2024-01-15T09:30:00Z' + modified_before: '2024-01-15T09:30:00Z' + page_size: 1 + remote_id: remote_id + team: team headers: X-Account-Token: X-Account-Token response: @@ -128,7 +140,8 @@ service: retrieve: path: /ticketing/v1/users/{id} method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a `User` object with the given `id`. source: openapi: ticketing_v3.yml @@ -160,6 +173,9 @@ service: examples: - path-parameters: id: id + query-parameters: + include_remote_data: true + include_shell_data: true headers: X-Account-Token: X-Account-Token response: diff --git a/.mock/definition/Ticketing/webhookReceivers.yml b/.mock/definition/Ticketing/webhookReceivers.yml index 68c2307b8..3a10d7758 100644 --- a/.mock/definition/Ticketing/webhookReceivers.yml +++ b/.mock/definition/Ticketing/webhookReceivers.yml @@ -7,7 +7,8 @@ service: list: path: /ticketing/v1/webhook-receivers method: GET - auth: true + auth: + - tokenAuth: [] docs: Returns a list of `WebhookReceiver` objects. source: openapi: ticketing_v3.yml @@ -26,7 +27,8 @@ service: create: path: /ticketing/v1/webhook-receivers method: POST - auth: true + auth: + - tokenAuth: [] docs: Creates a `WebhookReceiver` object with the given values. source: openapi: ticketing_v3.yml diff --git a/.mock/fern.config.json b/.mock/fern.config.json index 43adf15e6..9aef8fce9 100644 --- a/.mock/fern.config.json +++ b/.mock/fern.config.json @@ -1,4 +1,4 @@ { "organization" : "merge", - "version" : "0.66.29" + "version" : "0.83.0" } \ No newline at end of file diff --git a/README.md b/README.md index 23742ae47..5f08b643f 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ Add the dependency in your `pom.xml` file: dev.merge merge-java-client - 4.0.0 + 4.1.0 ``` diff --git a/build.gradle b/build.gradle index 2cc0aa644..664802e1e 100644 --- a/build.gradle +++ b/build.gradle @@ -21,6 +21,7 @@ dependencies { testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.2' testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.8.2' testImplementation 'org.junit.jupiter:junit-jupiter-params:5.8.2' + testImplementation 'com.squareup.okhttp3:mockwebserver:4.12.0' } @@ -47,7 +48,7 @@ java { group = 'dev.merge' -version = '4.0.0' +version = '5.0.0' jar { dependsOn(":generatePomFileForMavenPublication") @@ -70,6 +71,10 @@ test { useJUnitPlatform() testLogging { showStandardStreams = true + events "passed", "skipped", "failed" + exceptionFormat "short" + showExceptions true + showCauses true } } @@ -78,7 +83,7 @@ publishing { maven(MavenPublication) { groupId = 'dev.merge' artifactId = 'merge-java-client' - version = '4.0.0' + version = '5.0.0' from components.java pom { name = 'merge' diff --git a/src/main/java/com/merge/api/accounting/AsyncRawAccountingPeriodsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawAccountingPeriodsClient.java index 8e96030b6..66228b3bb 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawAccountingPeriodsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawAccountingPeriodsClient.java @@ -114,15 +114,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawAccountsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawAccountsClient.java index e83deb213..c497ac2ca 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawAccountsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawAccountsClient.java @@ -170,15 +170,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawAttachmentsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawAttachmentsClient.java index f7768372d..eb1302e65 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawAttachmentsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawAttachmentsClient.java @@ -145,15 +145,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawAuditTrailClient.java b/src/main/java/com/merge/api/accounting/AsyncRawAuditTrailClient.java index 3929d7565..1fa3cdd82 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawAuditTrailClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawAuditTrailClient.java @@ -109,15 +109,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawBalanceSheetsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawBalanceSheetsClient.java index 7d2972f84..f18b92a6a 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawBalanceSheetsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawBalanceSheetsClient.java @@ -140,15 +140,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawBankFeedAccountsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawBankFeedAccountsClient.java index fa7018bb8..74a7b3b90 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawBankFeedAccountsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawBankFeedAccountsClient.java @@ -120,15 +120,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawBankFeedTransactionsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawBankFeedTransactionsClient.java index 2f709c204..7ec0f2dc6 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawBankFeedTransactionsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawBankFeedTransactionsClient.java @@ -149,15 +149,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawCashFlowStatementsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawCashFlowStatementsClient.java index a9746c958..26652d49f 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawCashFlowStatementsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawCashFlowStatementsClient.java @@ -142,15 +142,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawCompanyInfoClient.java b/src/main/java/com/merge/api/accounting/AsyncRawCompanyInfoClient.java index 25c4f6d8f..9ce6da5dc 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawCompanyInfoClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawCompanyInfoClient.java @@ -136,15 +136,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawContactsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawContactsClient.java index e4892a40b..f78a5b65e 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawContactsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawContactsClient.java @@ -184,15 +184,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -528,15 +529,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawCreditNotesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawCreditNotesClient.java index e55ace46f..e68488516 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawCreditNotesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawCreditNotesClient.java @@ -169,15 +169,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawEmployeesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawEmployeesClient.java index b6c96552a..e8274e409 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawEmployeesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawEmployeesClient.java @@ -115,15 +115,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawExpensesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawExpensesClient.java index 2ab542f01..a7cb5375a 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawExpensesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawExpensesClient.java @@ -171,15 +171,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -451,15 +452,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return linesRemoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return linesRemoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -628,15 +630,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawGeneralLedgerTransactionsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawGeneralLedgerTransactionsClient.java index b5001983b..45f7d2f92 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawGeneralLedgerTransactionsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawGeneralLedgerTransactionsClient.java @@ -152,7 +152,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> { + startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/accounting/AsyncRawIncomeStatementsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawIncomeStatementsClient.java index 19706e6b4..901856583 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawIncomeStatementsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawIncomeStatementsClient.java @@ -141,15 +141,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawInvoicesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawInvoicesClient.java index 8de6021f0..a58033264 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawInvoicesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawInvoicesClient.java @@ -190,15 +190,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -558,15 +559,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return lineItemsRemoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return lineItemsRemoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -793,15 +795,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawIssuesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawIssuesClient.java index dbe7ef58d..425fdf966 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawIssuesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawIssuesClient.java @@ -155,7 +155,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/accounting/AsyncRawItemsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawItemsClient.java index 81f6e9671..f9d7934ce 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawItemsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawItemsClient.java @@ -155,7 +155,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/accounting/AsyncRawJournalEntriesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawJournalEntriesClient.java index fa141fa8a..9687e9388 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawJournalEntriesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawJournalEntriesClient.java @@ -172,15 +172,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -454,15 +455,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return linesRemoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return linesRemoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -631,15 +633,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawLinkedAccountsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawLinkedAccountsClient.java index 2aad47da7..5dc571861 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawLinkedAccountsClient.java @@ -150,7 +150,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> { + startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/accounting/AsyncRawPaymentMethodsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawPaymentMethodsClient.java index adb34af87..462cf91f6 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawPaymentMethodsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawPaymentMethodsClient.java @@ -112,15 +112,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawPaymentTermsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawPaymentTermsClient.java index cda3215ba..5b150f6c6 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawPaymentTermsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawPaymentTermsClient.java @@ -116,15 +116,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawPaymentsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawPaymentsClient.java index d1e3d2aaf..68efcb630 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawPaymentsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawPaymentsClient.java @@ -180,15 +180,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -538,15 +539,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return lineItemsRemoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return lineItemsRemoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -773,15 +775,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawPurchaseOrdersClient.java b/src/main/java/com/merge/api/accounting/AsyncRawPurchaseOrdersClient.java index e20b90526..717f741e6 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawPurchaseOrdersClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawPurchaseOrdersClient.java @@ -174,15 +174,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -466,15 +467,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return lineItemsRemoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return lineItemsRemoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -643,15 +645,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawSyncStatusClient.java b/src/main/java/com/merge/api/accounting/AsyncRawSyncStatusClient.java index 268d466b4..9eeeac6a1 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawSyncStatusClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawSyncStatusClient.java @@ -92,15 +92,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawTaxRatesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawTaxRatesClient.java index 388848d9e..b6f169e8a 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawTaxRatesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawTaxRatesClient.java @@ -143,15 +143,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawTrackingCategoriesClient.java b/src/main/java/com/merge/api/accounting/AsyncRawTrackingCategoriesClient.java index 2beba2676..bcc6c1202 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawTrackingCategoriesClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawTrackingCategoriesClient.java @@ -162,15 +162,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawTransactionsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawTransactionsClient.java index 9ecda18db..989497df2 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawTransactionsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawTransactionsClient.java @@ -154,15 +154,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/AsyncRawVendorCreditsClient.java b/src/main/java/com/merge/api/accounting/AsyncRawVendorCreditsClient.java index a369596db..e8c3921e9 100644 --- a/src/main/java/com/merge/api/accounting/AsyncRawVendorCreditsClient.java +++ b/src/main/java/com/merge/api/accounting/AsyncRawVendorCreditsClient.java @@ -161,15 +161,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/accounting/RawAccountingPeriodsClient.java b/src/main/java/com/merge/api/accounting/RawAccountingPeriodsClient.java index 817971513..08c269138 100644 --- a/src/main/java/com/merge/api/accounting/RawAccountingPeriodsClient.java +++ b/src/main/java/com/merge/api/accounting/RawAccountingPeriodsClient.java @@ -104,7 +104,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawAccountsClient.java b/src/main/java/com/merge/api/accounting/RawAccountsClient.java index 744f64a6d..c700c8e6b 100644 --- a/src/main/java/com/merge/api/accounting/RawAccountsClient.java +++ b/src/main/java/com/merge/api/accounting/RawAccountsClient.java @@ -162,9 +162,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/accounting/RawAttachmentsClient.java b/src/main/java/com/merge/api/accounting/RawAttachmentsClient.java index fc0f9b75d..95c6eb727 100644 --- a/src/main/java/com/merge/api/accounting/RawAttachmentsClient.java +++ b/src/main/java/com/merge/api/accounting/RawAttachmentsClient.java @@ -135,7 +135,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawAuditTrailClient.java b/src/main/java/com/merge/api/accounting/RawAuditTrailClient.java index 696f50eda..bbbb6d837 100644 --- a/src/main/java/com/merge/api/accounting/RawAuditTrailClient.java +++ b/src/main/java/com/merge/api/accounting/RawAuditTrailClient.java @@ -101,7 +101,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawBalanceSheetsClient.java b/src/main/java/com/merge/api/accounting/RawBalanceSheetsClient.java index c639460fa..e83b623c9 100644 --- a/src/main/java/com/merge/api/accounting/RawBalanceSheetsClient.java +++ b/src/main/java/com/merge/api/accounting/RawBalanceSheetsClient.java @@ -132,7 +132,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawBankFeedAccountsClient.java b/src/main/java/com/merge/api/accounting/RawBankFeedAccountsClient.java index e5b373b80..e4b49fdd2 100644 --- a/src/main/java/com/merge/api/accounting/RawBankFeedAccountsClient.java +++ b/src/main/java/com/merge/api/accounting/RawBankFeedAccountsClient.java @@ -111,7 +111,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawBankFeedTransactionsClient.java b/src/main/java/com/merge/api/accounting/RawBankFeedTransactionsClient.java index 10644246b..5047c6487 100644 --- a/src/main/java/com/merge/api/accounting/RawBankFeedTransactionsClient.java +++ b/src/main/java/com/merge/api/accounting/RawBankFeedTransactionsClient.java @@ -139,7 +139,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawCashFlowStatementsClient.java b/src/main/java/com/merge/api/accounting/RawCashFlowStatementsClient.java index 886a5ba7c..34cdc0093 100644 --- a/src/main/java/com/merge/api/accounting/RawCashFlowStatementsClient.java +++ b/src/main/java/com/merge/api/accounting/RawCashFlowStatementsClient.java @@ -132,7 +132,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawCompanyInfoClient.java b/src/main/java/com/merge/api/accounting/RawCompanyInfoClient.java index 7b0c754f0..78dc80cda 100644 --- a/src/main/java/com/merge/api/accounting/RawCompanyInfoClient.java +++ b/src/main/java/com/merge/api/accounting/RawCompanyInfoClient.java @@ -128,7 +128,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawContactsClient.java b/src/main/java/com/merge/api/accounting/RawContactsClient.java index c70e200b6..1d273fd3e 100644 --- a/src/main/java/com/merge/api/accounting/RawContactsClient.java +++ b/src/main/java/com/merge/api/accounting/RawContactsClient.java @@ -176,9 +176,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -457,7 +457,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/accounting/RawCreditNotesClient.java b/src/main/java/com/merge/api/accounting/RawCreditNotesClient.java index b987060fc..a5dda9f34 100644 --- a/src/main/java/com/merge/api/accounting/RawCreditNotesClient.java +++ b/src/main/java/com/merge/api/accounting/RawCreditNotesClient.java @@ -161,7 +161,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawEmployeesClient.java b/src/main/java/com/merge/api/accounting/RawEmployeesClient.java index 0044c053f..c4a2f287b 100644 --- a/src/main/java/com/merge/api/accounting/RawEmployeesClient.java +++ b/src/main/java/com/merge/api/accounting/RawEmployeesClient.java @@ -107,9 +107,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/accounting/RawExpensesClient.java b/src/main/java/com/merge/api/accounting/RawExpensesClient.java index 622ce7c79..e23eae6fb 100644 --- a/src/main/java/com/merge/api/accounting/RawExpensesClient.java +++ b/src/main/java/com/merge/api/accounting/RawExpensesClient.java @@ -163,9 +163,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -395,7 +395,7 @@ public MergeApiHttpResponse> linesRemoteFie List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> linesRemoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> linesRemoteFieldClassesList( nextRequest, requestOptions) .body()), response); @@ -537,7 +537,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/accounting/RawGeneralLedgerTransactionsClient.java b/src/main/java/com/merge/api/accounting/RawGeneralLedgerTransactionsClient.java index 9e68c2cdb..976c4fc1b 100644 --- a/src/main/java/com/merge/api/accounting/RawGeneralLedgerTransactionsClient.java +++ b/src/main/java/com/merge/api/accounting/RawGeneralLedgerTransactionsClient.java @@ -142,7 +142,8 @@ public MergeApiHttpResponse> list( parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawIncomeStatementsClient.java b/src/main/java/com/merge/api/accounting/RawIncomeStatementsClient.java index a5302f1c2..b02be95f5 100644 --- a/src/main/java/com/merge/api/accounting/RawIncomeStatementsClient.java +++ b/src/main/java/com/merge/api/accounting/RawIncomeStatementsClient.java @@ -132,7 +132,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawInvoicesClient.java b/src/main/java/com/merge/api/accounting/RawInvoicesClient.java index 0c95e705b..53fb1ed32 100644 --- a/src/main/java/com/merge/api/accounting/RawInvoicesClient.java +++ b/src/main/java/com/merge/api/accounting/RawInvoicesClient.java @@ -182,9 +182,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -485,8 +485,10 @@ public MergeApiHttpResponse> lineItemsRemot List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> lineItemsRemoteFieldClassesList( - nextRequest, requestOptions) + startingAfter.isPresent(), + result, + parsedResponse, + () -> lineItemsRemoteFieldClassesList(nextRequest, requestOptions) .body()), response); } @@ -670,7 +672,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/accounting/RawIssuesClient.java b/src/main/java/com/merge/api/accounting/RawIssuesClient.java index 87c8f5cce..dd539b014 100644 --- a/src/main/java/com/merge/api/accounting/RawIssuesClient.java +++ b/src/main/java/com/merge/api/accounting/RawIssuesClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/accounting/RawItemsClient.java b/src/main/java/com/merge/api/accounting/RawItemsClient.java index 92ffaa1a1..4d1d34d78 100644 --- a/src/main/java/com/merge/api/accounting/RawItemsClient.java +++ b/src/main/java/com/merge/api/accounting/RawItemsClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/accounting/RawJournalEntriesClient.java b/src/main/java/com/merge/api/accounting/RawJournalEntriesClient.java index e6f5d8bf0..d71523312 100644 --- a/src/main/java/com/merge/api/accounting/RawJournalEntriesClient.java +++ b/src/main/java/com/merge/api/accounting/RawJournalEntriesClient.java @@ -164,7 +164,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } @@ -397,7 +398,7 @@ public MergeApiHttpResponse> linesRemoteFie List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> linesRemoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> linesRemoteFieldClassesList( nextRequest, requestOptions) .body()), response); @@ -540,7 +541,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/accounting/RawLinkedAccountsClient.java b/src/main/java/com/merge/api/accounting/RawLinkedAccountsClient.java index 54fec84c9..68d2bd0c1 100644 --- a/src/main/java/com/merge/api/accounting/RawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/accounting/RawLinkedAccountsClient.java @@ -140,7 +140,8 @@ public MergeApiHttpResponse> list( parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawPaymentMethodsClient.java b/src/main/java/com/merge/api/accounting/RawPaymentMethodsClient.java index 7d2736a88..18ed9394c 100644 --- a/src/main/java/com/merge/api/accounting/RawPaymentMethodsClient.java +++ b/src/main/java/com/merge/api/accounting/RawPaymentMethodsClient.java @@ -104,7 +104,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawPaymentTermsClient.java b/src/main/java/com/merge/api/accounting/RawPaymentTermsClient.java index f68e4b2cb..778fb0ce0 100644 --- a/src/main/java/com/merge/api/accounting/RawPaymentTermsClient.java +++ b/src/main/java/com/merge/api/accounting/RawPaymentTermsClient.java @@ -108,7 +108,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawPaymentsClient.java b/src/main/java/com/merge/api/accounting/RawPaymentsClient.java index 355648629..723b07980 100644 --- a/src/main/java/com/merge/api/accounting/RawPaymentsClient.java +++ b/src/main/java/com/merge/api/accounting/RawPaymentsClient.java @@ -172,9 +172,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -465,8 +465,10 @@ public MergeApiHttpResponse> lineItemsRemot List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> lineItemsRemoteFieldClassesList( - nextRequest, requestOptions) + startingAfter.isPresent(), + result, + parsedResponse, + () -> lineItemsRemoteFieldClassesList(nextRequest, requestOptions) .body()), response); } @@ -650,7 +652,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/accounting/RawPurchaseOrdersClient.java b/src/main/java/com/merge/api/accounting/RawPurchaseOrdersClient.java index ac411ab2e..9994f919b 100644 --- a/src/main/java/com/merge/api/accounting/RawPurchaseOrdersClient.java +++ b/src/main/java/com/merge/api/accounting/RawPurchaseOrdersClient.java @@ -166,7 +166,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } @@ -407,8 +408,10 @@ public MergeApiHttpResponse> lineItemsRemot List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> lineItemsRemoteFieldClassesList( - nextRequest, requestOptions) + startingAfter.isPresent(), + result, + parsedResponse, + () -> lineItemsRemoteFieldClassesList(nextRequest, requestOptions) .body()), response); } @@ -550,7 +553,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/accounting/RawSyncStatusClient.java b/src/main/java/com/merge/api/accounting/RawSyncStatusClient.java index f21052dc8..7e4679be3 100644 --- a/src/main/java/com/merge/api/accounting/RawSyncStatusClient.java +++ b/src/main/java/com/merge/api/accounting/RawSyncStatusClient.java @@ -85,7 +85,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawTaxRatesClient.java b/src/main/java/com/merge/api/accounting/RawTaxRatesClient.java index fee288aa6..95fb7da60 100644 --- a/src/main/java/com/merge/api/accounting/RawTaxRatesClient.java +++ b/src/main/java/com/merge/api/accounting/RawTaxRatesClient.java @@ -135,9 +135,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/accounting/RawTrackingCategoriesClient.java b/src/main/java/com/merge/api/accounting/RawTrackingCategoriesClient.java index 17ce6b0e6..2f9370ef8 100644 --- a/src/main/java/com/merge/api/accounting/RawTrackingCategoriesClient.java +++ b/src/main/java/com/merge/api/accounting/RawTrackingCategoriesClient.java @@ -152,7 +152,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawTransactionsClient.java b/src/main/java/com/merge/api/accounting/RawTransactionsClient.java index d2ae4b429..47e5435b8 100644 --- a/src/main/java/com/merge/api/accounting/RawTransactionsClient.java +++ b/src/main/java/com/merge/api/accounting/RawTransactionsClient.java @@ -146,7 +146,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/RawVendorCreditsClient.java b/src/main/java/com/merge/api/accounting/RawVendorCreditsClient.java index 004c2e816..f3f9cf763 100644 --- a/src/main/java/com/merge/api/accounting/RawVendorCreditsClient.java +++ b/src/main/java/com/merge/api/accounting/RawVendorCreditsClient.java @@ -153,7 +153,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/accounting/types/AccountDetailsAndActionsIntegration.java b/src/main/java/com/merge/api/accounting/types/AccountDetailsAndActionsIntegration.java index 4da9a5381..d1f05e37f 100644 --- a/src/main/java/com/merge/api/accounting/types/AccountDetailsAndActionsIntegration.java +++ b/src/main/java/com/merge/api/accounting/types/AccountDetailsAndActionsIntegration.java @@ -309,7 +309,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/AccountResponse.java b/src/main/java/com/merge/api/accounting/types/AccountResponse.java index 1c253c58a..206a8dfad 100644 --- a/src/main/java/com/merge/api/accounting/types/AccountResponse.java +++ b/src/main/java/com/merge/api/accounting/types/AccountResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/AccountingAttachmentResponse.java b/src/main/java/com/merge/api/accounting/types/AccountingAttachmentResponse.java index bde8db4ff..5d8f90a71 100644 --- a/src/main/java/com/merge/api/accounting/types/AccountingAttachmentResponse.java +++ b/src/main/java/com/merge/api/accounting/types/AccountingAttachmentResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/AccountsListRequest.java b/src/main/java/com/merge/api/accounting/types/AccountsListRequest.java index a3e72930f..708801ac4 100644 --- a/src/main/java/com/merge/api/accounting/types/AccountsListRequest.java +++ b/src/main/java/com/merge/api/accounting/types/AccountsListRequest.java @@ -27,7 +27,7 @@ public final class AccountsListRequest { private final Optional accountType; - private final Optional classification; + private final Optional classification; private final Optional companyId; @@ -57,14 +57,14 @@ public final class AccountsListRequest { private final Optional showEnumOrigins; - private final Optional status; + private final Optional status; private final Map additionalProperties; private AccountsListRequest( Optional> expand, Optional accountType, - Optional classification, + Optional classification, Optional companyId, Optional createdAfter, Optional createdBefore, @@ -79,7 +79,7 @@ private AccountsListRequest( Optional remoteFields, Optional remoteId, Optional showEnumOrigins, - Optional status, + Optional status, Map additionalProperties) { this.expand = expand; this.accountType = accountType; @@ -122,7 +122,7 @@ public Optional getAccountType() { * @return If provided, will only return accounts with this classification. */ @JsonProperty("classification") - public Optional getClassification() { + public Optional getClassification() { return classification; } @@ -242,7 +242,7 @@ public Optional getShowEnumOrigins() { * @return If provided, will only return accounts with this status. */ @JsonProperty("status") - public Optional getStatus() { + public Optional getStatus() { return status; } @@ -316,7 +316,7 @@ public static final class Builder { private Optional accountType = Optional.empty(); - private Optional classification = Optional.empty(); + private Optional classification = Optional.empty(); private Optional companyId = Optional.empty(); @@ -346,7 +346,7 @@ public static final class Builder { private Optional showEnumOrigins = Optional.empty(); - private Optional status = Optional.empty(); + private Optional status = Optional.empty(); @JsonAnySetter private Map additionalProperties = new HashMap<>(); @@ -412,12 +412,12 @@ public Builder accountType(String accountType) { *

If provided, will only return accounts with this classification.

*/ @JsonSetter(value = "classification", nulls = Nulls.SKIP) - public Builder classification(Optional classification) { + public Builder classification(Optional classification) { this.classification = classification; return this; } - public Builder classification(String classification) { + public Builder classification(AccountsListRequestClassification classification) { this.classification = Optional.ofNullable(classification); return this; } @@ -622,12 +622,12 @@ public Builder showEnumOrigins(AccountsListRequestShowEnumOrigins showEnumOrigin *

If provided, will only return accounts with this status.

*/ @JsonSetter(value = "status", nulls = Nulls.SKIP) - public Builder status(Optional status) { + public Builder status(Optional status) { this.status = status; return this; } - public Builder status(String status) { + public Builder status(AccountsListRequestStatus status) { this.status = Optional.ofNullable(status); return this; } diff --git a/src/main/java/com/merge/api/accounting/types/AccountsListRequestClassification.java b/src/main/java/com/merge/api/accounting/types/AccountsListRequestClassification.java new file mode 100644 index 000000000..55c5490ef --- /dev/null +++ b/src/main/java/com/merge/api/accounting/types/AccountsListRequestClassification.java @@ -0,0 +1,130 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.merge.api.accounting.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class AccountsListRequestClassification { + public static final AccountsListRequestClassification EXPENSE = + new AccountsListRequestClassification(Value.EXPENSE, "EXPENSE"); + + public static final AccountsListRequestClassification ASSET = + new AccountsListRequestClassification(Value.ASSET, "ASSET"); + + public static final AccountsListRequestClassification REVENUE = + new AccountsListRequestClassification(Value.REVENUE, "REVENUE"); + + public static final AccountsListRequestClassification EQUITY = + new AccountsListRequestClassification(Value.EQUITY, "EQUITY"); + + public static final AccountsListRequestClassification LIABILITY = + new AccountsListRequestClassification(Value.LIABILITY, "LIABILITY"); + + public static final AccountsListRequestClassification EMPTY = + new AccountsListRequestClassification(Value.EMPTY, ""); + + private final Value value; + + private final String string; + + AccountsListRequestClassification(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof AccountsListRequestClassification + && this.string.equals(((AccountsListRequestClassification) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case EXPENSE: + return visitor.visitExpense(); + case ASSET: + return visitor.visitAsset(); + case REVENUE: + return visitor.visitRevenue(); + case EQUITY: + return visitor.visitEquity(); + case LIABILITY: + return visitor.visitLiability(); + case EMPTY: + return visitor.visitEmpty(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static AccountsListRequestClassification valueOf(String value) { + switch (value) { + case "EXPENSE": + return EXPENSE; + case "ASSET": + return ASSET; + case "REVENUE": + return REVENUE; + case "EQUITY": + return EQUITY; + case "LIABILITY": + return LIABILITY; + case "": + return EMPTY; + default: + return new AccountsListRequestClassification(Value.UNKNOWN, value); + } + } + + public enum Value { + EMPTY, + + ASSET, + + EQUITY, + + EXPENSE, + + LIABILITY, + + REVENUE, + + UNKNOWN + } + + public interface Visitor { + T visitEmpty(); + + T visitAsset(); + + T visitEquity(); + + T visitExpense(); + + T visitLiability(); + + T visitRevenue(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/main/java/com/merge/api/accounting/types/AccountsListRequestStatus.java b/src/main/java/com/merge/api/accounting/types/AccountsListRequestStatus.java new file mode 100644 index 000000000..8287fdf63 --- /dev/null +++ b/src/main/java/com/merge/api/accounting/types/AccountsListRequestStatus.java @@ -0,0 +1,104 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.merge.api.accounting.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class AccountsListRequestStatus { + public static final AccountsListRequestStatus ACTIVE = new AccountsListRequestStatus(Value.ACTIVE, "ACTIVE"); + + public static final AccountsListRequestStatus EMPTY = new AccountsListRequestStatus(Value.EMPTY, ""); + + public static final AccountsListRequestStatus INACTIVE = new AccountsListRequestStatus(Value.INACTIVE, "INACTIVE"); + + public static final AccountsListRequestStatus PENDING = new AccountsListRequestStatus(Value.PENDING, "PENDING"); + + private final Value value; + + private final String string; + + AccountsListRequestStatus(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof AccountsListRequestStatus + && this.string.equals(((AccountsListRequestStatus) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case ACTIVE: + return visitor.visitActive(); + case EMPTY: + return visitor.visitEmpty(); + case INACTIVE: + return visitor.visitInactive(); + case PENDING: + return visitor.visitPending(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static AccountsListRequestStatus valueOf(String value) { + switch (value) { + case "ACTIVE": + return ACTIVE; + case "": + return EMPTY; + case "INACTIVE": + return INACTIVE; + case "PENDING": + return PENDING; + default: + return new AccountsListRequestStatus(Value.UNKNOWN, value); + } + } + + public enum Value { + EMPTY, + + ACTIVE, + + INACTIVE, + + PENDING, + + UNKNOWN + } + + public interface Visitor { + T visitEmpty(); + + T visitActive(); + + T visitInactive(); + + T visitPending(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/main/java/com/merge/api/accounting/types/BankFeedAccountResponse.java b/src/main/java/com/merge/api/accounting/types/BankFeedAccountResponse.java index 691415831..448ddddbf 100644 --- a/src/main/java/com/merge/api/accounting/types/BankFeedAccountResponse.java +++ b/src/main/java/com/merge/api/accounting/types/BankFeedAccountResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/BankFeedTransactionResponse.java b/src/main/java/com/merge/api/accounting/types/BankFeedTransactionResponse.java index 4a95cb193..89d9b9beb 100644 --- a/src/main/java/com/merge/api/accounting/types/BankFeedTransactionResponse.java +++ b/src/main/java/com/merge/api/accounting/types/BankFeedTransactionResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/CommonModelScopeApi.java b/src/main/java/com/merge/api/accounting/types/CommonModelScopeApi.java index 41637940b..193404594 100644 --- a/src/main/java/com/merge/api/accounting/types/CommonModelScopeApi.java +++ b/src/main/java/com/merge/api/accounting/types/CommonModelScopeApi.java @@ -88,7 +88,9 @@ public Builder from(CommonModelScopeApi other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/CommonModelScopesBodyRequest.java b/src/main/java/com/merge/api/accounting/types/CommonModelScopesBodyRequest.java index 372d68e78..679345948 100644 --- a/src/main/java/com/merge/api/accounting/types/CommonModelScopesBodyRequest.java +++ b/src/main/java/com/merge/api/accounting/types/CommonModelScopesBodyRequest.java @@ -155,7 +155,9 @@ public _FinalStage addDisabledFields(String disabledFields) { @JsonSetter(value = "disabled_fields", nulls = Nulls.SKIP) public _FinalStage disabledFields(List disabledFields) { this.disabledFields.clear(); - this.disabledFields.addAll(disabledFields); + if (disabledFields != null) { + this.disabledFields.addAll(disabledFields); + } return this; } @@ -177,7 +179,9 @@ public _FinalStage addEnabledActions(EnabledActionsEnum enabledActions) { @JsonSetter(value = "enabled_actions", nulls = Nulls.SKIP) public _FinalStage enabledActions(List enabledActions) { this.enabledActions.clear(); - this.enabledActions.addAll(enabledActions); + if (enabledActions != null) { + this.enabledActions.addAll(enabledActions); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/ContactResponse.java b/src/main/java/com/merge/api/accounting/types/ContactResponse.java index 5510958f4..71ad37529 100644 --- a/src/main/java/com/merge/api/accounting/types/ContactResponse.java +++ b/src/main/java/com/merge/api/accounting/types/ContactResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/ContactsListRequest.java b/src/main/java/com/merge/api/accounting/types/ContactsListRequest.java index c87610dc3..57e892115 100644 --- a/src/main/java/com/merge/api/accounting/types/ContactsListRequest.java +++ b/src/main/java/com/merge/api/accounting/types/ContactsListRequest.java @@ -61,7 +61,7 @@ public final class ContactsListRequest { private final Optional showEnumOrigins; - private final Optional status; + private final Optional status; private final Map additionalProperties; @@ -85,7 +85,7 @@ private ContactsListRequest( Optional remoteFields, Optional remoteId, Optional showEnumOrigins, - Optional status, + Optional status, Map additionalProperties) { this.expand = expand; this.companyId = companyId; @@ -266,7 +266,7 @@ public Optional getShowEnumOrigins() { * @return If provided, will only return Contacts that match this status. */ @JsonProperty("status") - public Optional getStatus() { + public Optional getStatus() { return status; } @@ -378,7 +378,7 @@ public static final class Builder { private Optional showEnumOrigins = Optional.empty(); - private Optional status = Optional.empty(); + private Optional status = Optional.empty(); @JsonAnySetter private Map additionalProperties = new HashMap<>(); @@ -684,12 +684,12 @@ public Builder showEnumOrigins(String showEnumOrigins) { *

If provided, will only return Contacts that match this status.

*/ @JsonSetter(value = "status", nulls = Nulls.SKIP) - public Builder status(Optional status) { + public Builder status(Optional status) { this.status = status; return this; } - public Builder status(String status) { + public Builder status(ContactsListRequestStatus status) { this.status = Optional.ofNullable(status); return this; } diff --git a/src/main/java/com/merge/api/accounting/types/ContactsListRequestStatus.java b/src/main/java/com/merge/api/accounting/types/ContactsListRequestStatus.java new file mode 100644 index 000000000..2f6a82049 --- /dev/null +++ b/src/main/java/com/merge/api/accounting/types/ContactsListRequestStatus.java @@ -0,0 +1,94 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.merge.api.accounting.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class ContactsListRequestStatus { + public static final ContactsListRequestStatus ARCHIVED = new ContactsListRequestStatus(Value.ARCHIVED, "ARCHIVED"); + + public static final ContactsListRequestStatus ACTIVE = new ContactsListRequestStatus(Value.ACTIVE, "ACTIVE"); + + public static final ContactsListRequestStatus EMPTY = new ContactsListRequestStatus(Value.EMPTY, ""); + + private final Value value; + + private final String string; + + ContactsListRequestStatus(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof ContactsListRequestStatus + && this.string.equals(((ContactsListRequestStatus) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case ARCHIVED: + return visitor.visitArchived(); + case ACTIVE: + return visitor.visitActive(); + case EMPTY: + return visitor.visitEmpty(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static ContactsListRequestStatus valueOf(String value) { + switch (value) { + case "ARCHIVED": + return ARCHIVED; + case "ACTIVE": + return ACTIVE; + case "": + return EMPTY; + default: + return new ContactsListRequestStatus(Value.UNKNOWN, value); + } + } + + public enum Value { + EMPTY, + + ACTIVE, + + ARCHIVED, + + UNKNOWN + } + + public interface Visitor { + T visitEmpty(); + + T visitActive(); + + T visitArchived(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/main/java/com/merge/api/accounting/types/CreateFieldMappingRequest.java b/src/main/java/com/merge/api/accounting/types/CreateFieldMappingRequest.java index 6be7c0c55..1769cbb66 100644 --- a/src/main/java/com/merge/api/accounting/types/CreateFieldMappingRequest.java +++ b/src/main/java/com/merge/api/accounting/types/CreateFieldMappingRequest.java @@ -342,7 +342,9 @@ public _FinalStage addRemoteFieldTraversalPath(JsonNode remoteFieldTraversalPath @JsonSetter(value = "remote_field_traversal_path", nulls = Nulls.SKIP) public _FinalStage remoteFieldTraversalPath(List remoteFieldTraversalPath) { this.remoteFieldTraversalPath.clear(); - this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + if (remoteFieldTraversalPath != null) { + this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/CreditNoteResponse.java b/src/main/java/com/merge/api/accounting/types/CreditNoteResponse.java index 1cce465db..646996335 100644 --- a/src/main/java/com/merge/api/accounting/types/CreditNoteResponse.java +++ b/src/main/java/com/merge/api/accounting/types/CreditNoteResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/EndUserDetailsRequest.java b/src/main/java/com/merge/api/accounting/types/EndUserDetailsRequest.java index 4f0d83e13..ea6ef7f0f 100644 --- a/src/main/java/com/merge/api/accounting/types/EndUserDetailsRequest.java +++ b/src/main/java/com/merge/api/accounting/types/EndUserDetailsRequest.java @@ -663,7 +663,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/ExpenseResponse.java b/src/main/java/com/merge/api/accounting/types/ExpenseResponse.java index a8ee6833d..a9cbbfdcc 100644 --- a/src/main/java/com/merge/api/accounting/types/ExpenseResponse.java +++ b/src/main/java/com/merge/api/accounting/types/ExpenseResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/FieldMappingInstanceResponse.java b/src/main/java/com/merge/api/accounting/types/FieldMappingInstanceResponse.java index 2375e1e03..a848e30e7 100644 --- a/src/main/java/com/merge/api/accounting/types/FieldMappingInstanceResponse.java +++ b/src/main/java/com/merge/api/accounting/types/FieldMappingInstanceResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/InvoiceResponse.java b/src/main/java/com/merge/api/accounting/types/InvoiceResponse.java index 4b50f0a55..4132acda7 100644 --- a/src/main/java/com/merge/api/accounting/types/InvoiceResponse.java +++ b/src/main/java/com/merge/api/accounting/types/InvoiceResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/ItemResponse.java b/src/main/java/com/merge/api/accounting/types/ItemResponse.java index f65c5fe13..63f1227e5 100644 --- a/src/main/java/com/merge/api/accounting/types/ItemResponse.java +++ b/src/main/java/com/merge/api/accounting/types/ItemResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/JournalEntryResponse.java b/src/main/java/com/merge/api/accounting/types/JournalEntryResponse.java index f33df29eb..c848f9376 100644 --- a/src/main/java/com/merge/api/accounting/types/JournalEntryResponse.java +++ b/src/main/java/com/merge/api/accounting/types/JournalEntryResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/LinkedAccountCommonModelScopeDeserializerRequest.java b/src/main/java/com/merge/api/accounting/types/LinkedAccountCommonModelScopeDeserializerRequest.java index afcbdd15a..424b8fbe7 100644 --- a/src/main/java/com/merge/api/accounting/types/LinkedAccountCommonModelScopeDeserializerRequest.java +++ b/src/main/java/com/merge/api/accounting/types/LinkedAccountCommonModelScopeDeserializerRequest.java @@ -90,7 +90,9 @@ public Builder from(LinkedAccountCommonModelScopeDeserializerRequest other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/MetaResponse.java b/src/main/java/com/merge/api/accounting/types/MetaResponse.java index 6618ed2b4..d77906a50 100644 --- a/src/main/java/com/merge/api/accounting/types/MetaResponse.java +++ b/src/main/java/com/merge/api/accounting/types/MetaResponse.java @@ -226,7 +226,9 @@ public _FinalStage putAllRequestSchema(Map requestSchema) { @JsonSetter(value = "request_schema", nulls = Nulls.SKIP) public _FinalStage requestSchema(Map requestSchema) { this.requestSchema.clear(); - this.requestSchema.putAll(requestSchema); + if (requestSchema != null) { + this.requestSchema.putAll(requestSchema); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/ModelOperation.java b/src/main/java/com/merge/api/accounting/types/ModelOperation.java index 5af2e8187..090508093 100644 --- a/src/main/java/com/merge/api/accounting/types/ModelOperation.java +++ b/src/main/java/com/merge/api/accounting/types/ModelOperation.java @@ -175,7 +175,9 @@ public _FinalStage addSupportedFields(String supportedFields) { @JsonSetter(value = "supported_fields", nulls = Nulls.SKIP) public _FinalStage supportedFields(List supportedFields) { this.supportedFields.clear(); - this.supportedFields.addAll(supportedFields); + if (supportedFields != null) { + this.supportedFields.addAll(supportedFields); + } return this; } @@ -197,7 +199,9 @@ public _FinalStage addRequiredPostParameters(String requiredPostParameters) { @JsonSetter(value = "required_post_parameters", nulls = Nulls.SKIP) public _FinalStage requiredPostParameters(List requiredPostParameters) { this.requiredPostParameters.clear(); - this.requiredPostParameters.addAll(requiredPostParameters); + if (requiredPostParameters != null) { + this.requiredPostParameters.addAll(requiredPostParameters); + } return this; } @@ -219,7 +223,9 @@ public _FinalStage addAvailableOperations(String availableOperations) { @JsonSetter(value = "available_operations", nulls = Nulls.SKIP) public _FinalStage availableOperations(List availableOperations) { this.availableOperations.clear(); - this.availableOperations.addAll(availableOperations); + if (availableOperations != null) { + this.availableOperations.addAll(availableOperations); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/PaymentResponse.java b/src/main/java/com/merge/api/accounting/types/PaymentResponse.java index 725071d1f..f1b546306 100644 --- a/src/main/java/com/merge/api/accounting/types/PaymentResponse.java +++ b/src/main/java/com/merge/api/accounting/types/PaymentResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/PurchaseOrderResponse.java b/src/main/java/com/merge/api/accounting/types/PurchaseOrderResponse.java index dd82011ac..289626c30 100644 --- a/src/main/java/com/merge/api/accounting/types/PurchaseOrderResponse.java +++ b/src/main/java/com/merge/api/accounting/types/PurchaseOrderResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/RemoteEndpointInfo.java b/src/main/java/com/merge/api/accounting/types/RemoteEndpointInfo.java index b91f9917b..d629693b3 100644 --- a/src/main/java/com/merge/api/accounting/types/RemoteEndpointInfo.java +++ b/src/main/java/com/merge/api/accounting/types/RemoteEndpointInfo.java @@ -161,7 +161,9 @@ public _FinalStage addFieldTraversalPath(JsonNode fieldTraversalPath) { @JsonSetter(value = "field_traversal_path", nulls = Nulls.SKIP) public _FinalStage fieldTraversalPath(List fieldTraversalPath) { this.fieldTraversalPath.clear(); - this.fieldTraversalPath.addAll(fieldTraversalPath); + if (fieldTraversalPath != null) { + this.fieldTraversalPath.addAll(fieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/RemoteFieldApi.java b/src/main/java/com/merge/api/accounting/types/RemoteFieldApi.java index 295f4e39e..8804c40f2 100644 --- a/src/main/java/com/merge/api/accounting/types/RemoteFieldApi.java +++ b/src/main/java/com/merge/api/accounting/types/RemoteFieldApi.java @@ -258,7 +258,9 @@ public _FinalStage putAllSchema(Map schema) { @JsonSetter(value = "schema", nulls = Nulls.SKIP) public _FinalStage schema(Map schema) { this.schema.clear(); - this.schema.putAll(schema); + if (schema != null) { + this.schema.putAll(schema); + } return this; } diff --git a/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequest.java b/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequest.java index 6718e4246..5ccfd48f7 100644 --- a/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequest.java +++ b/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequest.java @@ -25,7 +25,7 @@ public final class TrackingCategoriesListRequest { private final Optional> expand; - private final Optional categoryType; + private final Optional categoryType; private final Optional companyId; @@ -55,13 +55,13 @@ public final class TrackingCategoriesListRequest { private final Optional showEnumOrigins; - private final Optional status; + private final Optional status; private final Map additionalProperties; private TrackingCategoriesListRequest( Optional> expand, - Optional categoryType, + Optional categoryType, Optional companyId, Optional createdAfter, Optional createdBefore, @@ -76,7 +76,7 @@ private TrackingCategoriesListRequest( Optional remoteFields, Optional remoteId, Optional showEnumOrigins, - Optional status, + Optional status, Map additionalProperties) { this.expand = expand; this.categoryType = categoryType; @@ -110,7 +110,7 @@ public Optional> getExpand() { * @return If provided, will only return tracking categories with this type. */ @JsonProperty("category_type") - public Optional getCategoryType() { + public Optional getCategoryType() { return categoryType; } @@ -230,7 +230,7 @@ public Optional getShowEnumOrigins() { * @return If provided, will only return tracking categories with this status. */ @JsonProperty("status") - public Optional getStatus() { + public Optional getStatus() { return status; } @@ -300,7 +300,7 @@ public static Builder builder() { public static final class Builder { private Optional> expand = Optional.empty(); - private Optional categoryType = Optional.empty(); + private Optional categoryType = Optional.empty(); private Optional companyId = Optional.empty(); @@ -330,7 +330,7 @@ public static final class Builder { private Optional showEnumOrigins = Optional.empty(); - private Optional status = Optional.empty(); + private Optional status = Optional.empty(); @JsonAnySetter private Map additionalProperties = new HashMap<>(); @@ -381,12 +381,12 @@ public Builder expand(String expand) { *

If provided, will only return tracking categories with this type.

*/ @JsonSetter(value = "category_type", nulls = Nulls.SKIP) - public Builder categoryType(Optional categoryType) { + public Builder categoryType(Optional categoryType) { this.categoryType = categoryType; return this; } - public Builder categoryType(String categoryType) { + public Builder categoryType(TrackingCategoriesListRequestCategoryType categoryType) { this.categoryType = Optional.ofNullable(categoryType); return this; } @@ -591,12 +591,12 @@ public Builder showEnumOrigins(String showEnumOrigins) { *

If provided, will only return tracking categories with this status.

*/ @JsonSetter(value = "status", nulls = Nulls.SKIP) - public Builder status(Optional status) { + public Builder status(Optional status) { this.status = status; return this; } - public Builder status(String status) { + public Builder status(TrackingCategoriesListRequestStatus status) { this.status = Optional.ofNullable(status); return this; } diff --git a/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequestCategoryType.java b/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequestCategoryType.java new file mode 100644 index 000000000..b44f8bad6 --- /dev/null +++ b/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequestCategoryType.java @@ -0,0 +1,97 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.merge.api.accounting.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class TrackingCategoriesListRequestCategoryType { + public static final TrackingCategoriesListRequestCategoryType EMPTY = + new TrackingCategoriesListRequestCategoryType(Value.EMPTY, ""); + + public static final TrackingCategoriesListRequestCategoryType CLASS = + new TrackingCategoriesListRequestCategoryType(Value.CLASS, "CLASS"); + + public static final TrackingCategoriesListRequestCategoryType DEPARTMENT = + new TrackingCategoriesListRequestCategoryType(Value.DEPARTMENT, "DEPARTMENT"); + + private final Value value; + + private final String string; + + TrackingCategoriesListRequestCategoryType(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof TrackingCategoriesListRequestCategoryType + && this.string.equals(((TrackingCategoriesListRequestCategoryType) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case EMPTY: + return visitor.visitEmpty(); + case CLASS: + return visitor.visitClass(); + case DEPARTMENT: + return visitor.visitDepartment(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static TrackingCategoriesListRequestCategoryType valueOf(String value) { + switch (value) { + case "": + return EMPTY; + case "CLASS": + return CLASS; + case "DEPARTMENT": + return DEPARTMENT; + default: + return new TrackingCategoriesListRequestCategoryType(Value.UNKNOWN, value); + } + } + + public enum Value { + EMPTY, + + CLASS, + + DEPARTMENT, + + UNKNOWN + } + + public interface Visitor { + T visitEmpty(); + + T visitClass(); + + T visitDepartment(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequestStatus.java b/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequestStatus.java new file mode 100644 index 000000000..c2d75436b --- /dev/null +++ b/src/main/java/com/merge/api/accounting/types/TrackingCategoriesListRequestStatus.java @@ -0,0 +1,97 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.merge.api.accounting.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class TrackingCategoriesListRequestStatus { + public static final TrackingCategoriesListRequestStatus ARCHIVED = + new TrackingCategoriesListRequestStatus(Value.ARCHIVED, "ARCHIVED"); + + public static final TrackingCategoriesListRequestStatus ACTIVE = + new TrackingCategoriesListRequestStatus(Value.ACTIVE, "ACTIVE"); + + public static final TrackingCategoriesListRequestStatus EMPTY = + new TrackingCategoriesListRequestStatus(Value.EMPTY, ""); + + private final Value value; + + private final String string; + + TrackingCategoriesListRequestStatus(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof TrackingCategoriesListRequestStatus + && this.string.equals(((TrackingCategoriesListRequestStatus) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case ARCHIVED: + return visitor.visitArchived(); + case ACTIVE: + return visitor.visitActive(); + case EMPTY: + return visitor.visitEmpty(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static TrackingCategoriesListRequestStatus valueOf(String value) { + switch (value) { + case "ARCHIVED": + return ARCHIVED; + case "ACTIVE": + return ACTIVE; + case "": + return EMPTY; + default: + return new TrackingCategoriesListRequestStatus(Value.UNKNOWN, value); + } + } + + public enum Value { + EMPTY, + + ACTIVE, + + ARCHIVED, + + UNKNOWN + } + + public interface Visitor { + T visitEmpty(); + + T visitActive(); + + T visitArchived(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/main/java/com/merge/api/accounting/types/VendorCreditResponse.java b/src/main/java/com/merge/api/accounting/types/VendorCreditResponse.java index c6096b7bb..35b7cd070 100644 --- a/src/main/java/com/merge/api/accounting/types/VendorCreditResponse.java +++ b/src/main/java/com/merge/api/accounting/types/VendorCreditResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawActivitiesClient.java b/src/main/java/com/merge/api/ats/AsyncRawActivitiesClient.java index 4020ff739..f2b220afa 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawActivitiesClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawActivitiesClient.java @@ -154,15 +154,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawApplicationsClient.java b/src/main/java/com/merge/api/ats/AsyncRawApplicationsClient.java index 1e67665eb..844da1578 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawApplicationsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawApplicationsClient.java @@ -169,15 +169,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawAttachmentsClient.java b/src/main/java/com/merge/api/ats/AsyncRawAttachmentsClient.java index 194420625..363f95acc 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawAttachmentsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawAttachmentsClient.java @@ -155,15 +155,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawAuditTrailClient.java b/src/main/java/com/merge/api/ats/AsyncRawAuditTrailClient.java index d36eff89b..6d26ba9db 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawAuditTrailClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawAuditTrailClient.java @@ -109,15 +109,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawCandidatesClient.java b/src/main/java/com/merge/api/ats/AsyncRawCandidatesClient.java index 64fbb7509..2cbebbbf9 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawCandidatesClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawCandidatesClient.java @@ -161,15 +161,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawDepartmentsClient.java b/src/main/java/com/merge/api/ats/AsyncRawDepartmentsClient.java index daa9de755..a27ebbde7 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawDepartmentsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawDepartmentsClient.java @@ -132,15 +132,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawEeocsClient.java b/src/main/java/com/merge/api/ats/AsyncRawEeocsClient.java index 45e6109f3..b8de1feef 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawEeocsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawEeocsClient.java @@ -147,7 +147,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ats/AsyncRawInterviewsClient.java b/src/main/java/com/merge/api/ats/AsyncRawInterviewsClient.java index ed099a3e2..fe78fcf54 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawInterviewsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawInterviewsClient.java @@ -172,15 +172,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawIssuesClient.java b/src/main/java/com/merge/api/ats/AsyncRawIssuesClient.java index 817b28fc5..cf29392f7 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawIssuesClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawIssuesClient.java @@ -155,7 +155,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ats/AsyncRawJobInterviewStagesClient.java b/src/main/java/com/merge/api/ats/AsyncRawJobInterviewStagesClient.java index 7203a1c13..8a3ee758b 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawJobInterviewStagesClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawJobInterviewStagesClient.java @@ -142,15 +142,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawJobPostingsClient.java b/src/main/java/com/merge/api/ats/AsyncRawJobPostingsClient.java index 8fc0a37c1..69f91bdb8 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawJobPostingsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawJobPostingsClient.java @@ -140,15 +140,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawJobsClient.java b/src/main/java/com/merge/api/ats/AsyncRawJobsClient.java index 6219de166..9e9d8723d 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawJobsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawJobsClient.java @@ -158,7 +158,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() @@ -360,15 +360,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return screeningQuestionsList(jobId, nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return screeningQuestionsList(jobId, nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawLinkedAccountsClient.java b/src/main/java/com/merge/api/ats/AsyncRawLinkedAccountsClient.java index b340b4c26..004dd82b6 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawLinkedAccountsClient.java @@ -150,7 +150,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> { + startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ats/AsyncRawOffersClient.java b/src/main/java/com/merge/api/ats/AsyncRawOffersClient.java index 497709878..a558e70e0 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawOffersClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawOffersClient.java @@ -151,7 +151,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ats/AsyncRawOfficesClient.java b/src/main/java/com/merge/api/ats/AsyncRawOfficesClient.java index bc281171a..0a8158af9 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawOfficesClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawOfficesClient.java @@ -131,15 +131,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawRejectReasonsClient.java b/src/main/java/com/merge/api/ats/AsyncRawRejectReasonsClient.java index 5f47a282b..2ba7f682b 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawRejectReasonsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawRejectReasonsClient.java @@ -132,15 +132,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawScorecardsClient.java b/src/main/java/com/merge/api/ats/AsyncRawScorecardsClient.java index 4403e5b6f..7cc715c44 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawScorecardsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawScorecardsClient.java @@ -155,15 +155,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawSyncStatusClient.java b/src/main/java/com/merge/api/ats/AsyncRawSyncStatusClient.java index 54460d781..dbea60b99 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawSyncStatusClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawSyncStatusClient.java @@ -92,15 +92,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/AsyncRawTagsClient.java b/src/main/java/com/merge/api/ats/AsyncRawTagsClient.java index 2dfd9533d..066a73215 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawTagsClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawTagsClient.java @@ -130,7 +130,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ats/AsyncRawUsersClient.java b/src/main/java/com/merge/api/ats/AsyncRawUsersClient.java index 1f6eff069..f42e93de9 100644 --- a/src/main/java/com/merge/api/ats/AsyncRawUsersClient.java +++ b/src/main/java/com/merge/api/ats/AsyncRawUsersClient.java @@ -143,15 +143,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ats/RawActivitiesClient.java b/src/main/java/com/merge/api/ats/RawActivitiesClient.java index 7bce6fbef..83b35924e 100644 --- a/src/main/java/com/merge/api/ats/RawActivitiesClient.java +++ b/src/main/java/com/merge/api/ats/RawActivitiesClient.java @@ -146,9 +146,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawApplicationsClient.java b/src/main/java/com/merge/api/ats/RawApplicationsClient.java index e83f44e5e..02c628c7c 100644 --- a/src/main/java/com/merge/api/ats/RawApplicationsClient.java +++ b/src/main/java/com/merge/api/ats/RawApplicationsClient.java @@ -161,7 +161,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawAttachmentsClient.java b/src/main/java/com/merge/api/ats/RawAttachmentsClient.java index 4c82a4d40..c640eab44 100644 --- a/src/main/java/com/merge/api/ats/RawAttachmentsClient.java +++ b/src/main/java/com/merge/api/ats/RawAttachmentsClient.java @@ -147,7 +147,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawAuditTrailClient.java b/src/main/java/com/merge/api/ats/RawAuditTrailClient.java index 7caa79372..71d09b7b0 100644 --- a/src/main/java/com/merge/api/ats/RawAuditTrailClient.java +++ b/src/main/java/com/merge/api/ats/RawAuditTrailClient.java @@ -101,7 +101,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawCandidatesClient.java b/src/main/java/com/merge/api/ats/RawCandidatesClient.java index eb6f9712f..39ddae212 100644 --- a/src/main/java/com/merge/api/ats/RawCandidatesClient.java +++ b/src/main/java/com/merge/api/ats/RawCandidatesClient.java @@ -153,9 +153,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawDepartmentsClient.java b/src/main/java/com/merge/api/ats/RawDepartmentsClient.java index 4befb9e31..aa787ef3f 100644 --- a/src/main/java/com/merge/api/ats/RawDepartmentsClient.java +++ b/src/main/java/com/merge/api/ats/RawDepartmentsClient.java @@ -124,7 +124,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawEeocsClient.java b/src/main/java/com/merge/api/ats/RawEeocsClient.java index a8858f92e..757c5f1de 100644 --- a/src/main/java/com/merge/api/ats/RawEeocsClient.java +++ b/src/main/java/com/merge/api/ats/RawEeocsClient.java @@ -139,9 +139,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawInterviewsClient.java b/src/main/java/com/merge/api/ats/RawInterviewsClient.java index d0fb14f5e..347a49239 100644 --- a/src/main/java/com/merge/api/ats/RawInterviewsClient.java +++ b/src/main/java/com/merge/api/ats/RawInterviewsClient.java @@ -162,7 +162,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawIssuesClient.java b/src/main/java/com/merge/api/ats/RawIssuesClient.java index 804311293..fe32d31e7 100644 --- a/src/main/java/com/merge/api/ats/RawIssuesClient.java +++ b/src/main/java/com/merge/api/ats/RawIssuesClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawJobInterviewStagesClient.java b/src/main/java/com/merge/api/ats/RawJobInterviewStagesClient.java index 05d0939bd..9cfdac863 100644 --- a/src/main/java/com/merge/api/ats/RawJobInterviewStagesClient.java +++ b/src/main/java/com/merge/api/ats/RawJobInterviewStagesClient.java @@ -132,7 +132,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawJobPostingsClient.java b/src/main/java/com/merge/api/ats/RawJobPostingsClient.java index a134cf1ea..c2092e589 100644 --- a/src/main/java/com/merge/api/ats/RawJobPostingsClient.java +++ b/src/main/java/com/merge/api/ats/RawJobPostingsClient.java @@ -132,7 +132,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawJobsClient.java b/src/main/java/com/merge/api/ats/RawJobsClient.java index 542815d85..d68bd444a 100644 --- a/src/main/java/com/merge/api/ats/RawJobsClient.java +++ b/src/main/java/com/merge/api/ats/RawJobsClient.java @@ -149,9 +149,9 @@ public MergeApiHttpResponse> list(JobsListRequest reques .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -316,7 +316,7 @@ public MergeApiHttpResponse> screeningQues List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> screeningQuestionsList( + startingAfter.isPresent(), result, parsedResponse, () -> screeningQuestionsList( jobId, nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/ats/RawLinkedAccountsClient.java b/src/main/java/com/merge/api/ats/RawLinkedAccountsClient.java index d611eb03f..38de4f704 100644 --- a/src/main/java/com/merge/api/ats/RawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/ats/RawLinkedAccountsClient.java @@ -140,7 +140,8 @@ public MergeApiHttpResponse> list( parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawOffersClient.java b/src/main/java/com/merge/api/ats/RawOffersClient.java index 18b4182e4..4e5777f10 100644 --- a/src/main/java/com/merge/api/ats/RawOffersClient.java +++ b/src/main/java/com/merge/api/ats/RawOffersClient.java @@ -143,9 +143,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawOfficesClient.java b/src/main/java/com/merge/api/ats/RawOfficesClient.java index 0a33a356d..d4ce078d8 100644 --- a/src/main/java/com/merge/api/ats/RawOfficesClient.java +++ b/src/main/java/com/merge/api/ats/RawOfficesClient.java @@ -123,9 +123,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawRejectReasonsClient.java b/src/main/java/com/merge/api/ats/RawRejectReasonsClient.java index ff339be3c..2a0471b1d 100644 --- a/src/main/java/com/merge/api/ats/RawRejectReasonsClient.java +++ b/src/main/java/com/merge/api/ats/RawRejectReasonsClient.java @@ -124,7 +124,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawScorecardsClient.java b/src/main/java/com/merge/api/ats/RawScorecardsClient.java index a05f5a1b9..7dab6d7f0 100644 --- a/src/main/java/com/merge/api/ats/RawScorecardsClient.java +++ b/src/main/java/com/merge/api/ats/RawScorecardsClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawSyncStatusClient.java b/src/main/java/com/merge/api/ats/RawSyncStatusClient.java index 160101b73..561a6145a 100644 --- a/src/main/java/com/merge/api/ats/RawSyncStatusClient.java +++ b/src/main/java/com/merge/api/ats/RawSyncStatusClient.java @@ -85,7 +85,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/RawTagsClient.java b/src/main/java/com/merge/api/ats/RawTagsClient.java index 47708ca1b..0aeb7bda1 100644 --- a/src/main/java/com/merge/api/ats/RawTagsClient.java +++ b/src/main/java/com/merge/api/ats/RawTagsClient.java @@ -121,9 +121,9 @@ public MergeApiHttpResponse> list(TagsListRequest reques .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ats/RawUsersClient.java b/src/main/java/com/merge/api/ats/RawUsersClient.java index 8bbd9f9d5..19b0f7a85 100644 --- a/src/main/java/com/merge/api/ats/RawUsersClient.java +++ b/src/main/java/com/merge/api/ats/RawUsersClient.java @@ -136,7 +136,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ats/types/AccountDetailsAndActionsIntegration.java b/src/main/java/com/merge/api/ats/types/AccountDetailsAndActionsIntegration.java index 581c8a141..b5a1dc957 100644 --- a/src/main/java/com/merge/api/ats/types/AccountDetailsAndActionsIntegration.java +++ b/src/main/java/com/merge/api/ats/types/AccountDetailsAndActionsIntegration.java @@ -309,7 +309,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/ActivityResponse.java b/src/main/java/com/merge/api/ats/types/ActivityResponse.java index 3e1a863cb..ccd967077 100644 --- a/src/main/java/com/merge/api/ats/types/ActivityResponse.java +++ b/src/main/java/com/merge/api/ats/types/ActivityResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/ApplicationResponse.java b/src/main/java/com/merge/api/ats/types/ApplicationResponse.java index 920dbaf65..335287b54 100644 --- a/src/main/java/com/merge/api/ats/types/ApplicationResponse.java +++ b/src/main/java/com/merge/api/ats/types/ApplicationResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/AttachmentResponse.java b/src/main/java/com/merge/api/ats/types/AttachmentResponse.java index 40d629629..a596fb0c5 100644 --- a/src/main/java/com/merge/api/ats/types/AttachmentResponse.java +++ b/src/main/java/com/merge/api/ats/types/AttachmentResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/CandidateResponse.java b/src/main/java/com/merge/api/ats/types/CandidateResponse.java index 3887c2b92..586730282 100644 --- a/src/main/java/com/merge/api/ats/types/CandidateResponse.java +++ b/src/main/java/com/merge/api/ats/types/CandidateResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/CommonModelScopeApi.java b/src/main/java/com/merge/api/ats/types/CommonModelScopeApi.java index 0bfcfd0ed..6f34b79a6 100644 --- a/src/main/java/com/merge/api/ats/types/CommonModelScopeApi.java +++ b/src/main/java/com/merge/api/ats/types/CommonModelScopeApi.java @@ -88,7 +88,9 @@ public Builder from(CommonModelScopeApi other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/CommonModelScopesBodyRequest.java b/src/main/java/com/merge/api/ats/types/CommonModelScopesBodyRequest.java index 6c2318554..e8afbb2d0 100644 --- a/src/main/java/com/merge/api/ats/types/CommonModelScopesBodyRequest.java +++ b/src/main/java/com/merge/api/ats/types/CommonModelScopesBodyRequest.java @@ -155,7 +155,9 @@ public _FinalStage addDisabledFields(String disabledFields) { @JsonSetter(value = "disabled_fields", nulls = Nulls.SKIP) public _FinalStage disabledFields(List disabledFields) { this.disabledFields.clear(); - this.disabledFields.addAll(disabledFields); + if (disabledFields != null) { + this.disabledFields.addAll(disabledFields); + } return this; } @@ -177,7 +179,9 @@ public _FinalStage addEnabledActions(EnabledActionsEnum enabledActions) { @JsonSetter(value = "enabled_actions", nulls = Nulls.SKIP) public _FinalStage enabledActions(List enabledActions) { this.enabledActions.clear(); - this.enabledActions.addAll(enabledActions); + if (enabledActions != null) { + this.enabledActions.addAll(enabledActions); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/CreateFieldMappingRequest.java b/src/main/java/com/merge/api/ats/types/CreateFieldMappingRequest.java index 0ed30e1d0..32e46ee62 100644 --- a/src/main/java/com/merge/api/ats/types/CreateFieldMappingRequest.java +++ b/src/main/java/com/merge/api/ats/types/CreateFieldMappingRequest.java @@ -342,7 +342,9 @@ public _FinalStage addRemoteFieldTraversalPath(JsonNode remoteFieldTraversalPath @JsonSetter(value = "remote_field_traversal_path", nulls = Nulls.SKIP) public _FinalStage remoteFieldTraversalPath(List remoteFieldTraversalPath) { this.remoteFieldTraversalPath.clear(); - this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + if (remoteFieldTraversalPath != null) { + this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/EndUserDetailsRequest.java b/src/main/java/com/merge/api/ats/types/EndUserDetailsRequest.java index edbc5bea9..f2845798c 100644 --- a/src/main/java/com/merge/api/ats/types/EndUserDetailsRequest.java +++ b/src/main/java/com/merge/api/ats/types/EndUserDetailsRequest.java @@ -663,7 +663,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/FieldMappingInstanceResponse.java b/src/main/java/com/merge/api/ats/types/FieldMappingInstanceResponse.java index a3edb7c4a..8ca11b09c 100644 --- a/src/main/java/com/merge/api/ats/types/FieldMappingInstanceResponse.java +++ b/src/main/java/com/merge/api/ats/types/FieldMappingInstanceResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/LinkedAccountCommonModelScopeDeserializerRequest.java b/src/main/java/com/merge/api/ats/types/LinkedAccountCommonModelScopeDeserializerRequest.java index 8f0503f34..59192a924 100644 --- a/src/main/java/com/merge/api/ats/types/LinkedAccountCommonModelScopeDeserializerRequest.java +++ b/src/main/java/com/merge/api/ats/types/LinkedAccountCommonModelScopeDeserializerRequest.java @@ -90,7 +90,9 @@ public Builder from(LinkedAccountCommonModelScopeDeserializerRequest other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/MetaResponse.java b/src/main/java/com/merge/api/ats/types/MetaResponse.java index 38884d8cb..d8df38c5e 100644 --- a/src/main/java/com/merge/api/ats/types/MetaResponse.java +++ b/src/main/java/com/merge/api/ats/types/MetaResponse.java @@ -226,7 +226,9 @@ public _FinalStage putAllRequestSchema(Map requestSchema) { @JsonSetter(value = "request_schema", nulls = Nulls.SKIP) public _FinalStage requestSchema(Map requestSchema) { this.requestSchema.clear(); - this.requestSchema.putAll(requestSchema); + if (requestSchema != null) { + this.requestSchema.putAll(requestSchema); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/ModelOperation.java b/src/main/java/com/merge/api/ats/types/ModelOperation.java index 781a6feb6..cdd011f43 100644 --- a/src/main/java/com/merge/api/ats/types/ModelOperation.java +++ b/src/main/java/com/merge/api/ats/types/ModelOperation.java @@ -175,7 +175,9 @@ public _FinalStage addSupportedFields(String supportedFields) { @JsonSetter(value = "supported_fields", nulls = Nulls.SKIP) public _FinalStage supportedFields(List supportedFields) { this.supportedFields.clear(); - this.supportedFields.addAll(supportedFields); + if (supportedFields != null) { + this.supportedFields.addAll(supportedFields); + } return this; } @@ -197,7 +199,9 @@ public _FinalStage addRequiredPostParameters(String requiredPostParameters) { @JsonSetter(value = "required_post_parameters", nulls = Nulls.SKIP) public _FinalStage requiredPostParameters(List requiredPostParameters) { this.requiredPostParameters.clear(); - this.requiredPostParameters.addAll(requiredPostParameters); + if (requiredPostParameters != null) { + this.requiredPostParameters.addAll(requiredPostParameters); + } return this; } @@ -219,7 +223,9 @@ public _FinalStage addAvailableOperations(String availableOperations) { @JsonSetter(value = "available_operations", nulls = Nulls.SKIP) public _FinalStage availableOperations(List availableOperations) { this.availableOperations.clear(); - this.availableOperations.addAll(availableOperations); + if (availableOperations != null) { + this.availableOperations.addAll(availableOperations); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/RemoteEndpointInfo.java b/src/main/java/com/merge/api/ats/types/RemoteEndpointInfo.java index f5e527498..1cc512e98 100644 --- a/src/main/java/com/merge/api/ats/types/RemoteEndpointInfo.java +++ b/src/main/java/com/merge/api/ats/types/RemoteEndpointInfo.java @@ -161,7 +161,9 @@ public _FinalStage addFieldTraversalPath(JsonNode fieldTraversalPath) { @JsonSetter(value = "field_traversal_path", nulls = Nulls.SKIP) public _FinalStage fieldTraversalPath(List fieldTraversalPath) { this.fieldTraversalPath.clear(); - this.fieldTraversalPath.addAll(fieldTraversalPath); + if (fieldTraversalPath != null) { + this.fieldTraversalPath.addAll(fieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/RemoteFieldApi.java b/src/main/java/com/merge/api/ats/types/RemoteFieldApi.java index 6bf72b3f2..40a032021 100644 --- a/src/main/java/com/merge/api/ats/types/RemoteFieldApi.java +++ b/src/main/java/com/merge/api/ats/types/RemoteFieldApi.java @@ -258,7 +258,9 @@ public _FinalStage putAllSchema(Map schema) { @JsonSetter(value = "schema", nulls = Nulls.SKIP) public _FinalStage schema(Map schema) { this.schema.clear(); - this.schema.putAll(schema); + if (schema != null) { + this.schema.putAll(schema); + } return this; } diff --git a/src/main/java/com/merge/api/ats/types/ScheduledInterviewResponse.java b/src/main/java/com/merge/api/ats/types/ScheduledInterviewResponse.java index 532221d23..3bc1a7a65 100644 --- a/src/main/java/com/merge/api/ats/types/ScheduledInterviewResponse.java +++ b/src/main/java/com/merge/api/ats/types/ScheduledInterviewResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/core/BasePage.java b/src/main/java/com/merge/api/core/BasePage.java index 2cbc98940..12ca91667 100644 --- a/src/main/java/com/merge/api/core/BasePage.java +++ b/src/main/java/com/merge/api/core/BasePage.java @@ -4,14 +4,17 @@ package com.merge.api.core; import java.util.List; +import java.util.Optional; public abstract class BasePage { private final boolean hasNext; private final List items; + private final Object response; - public BasePage(boolean hasNext, List items) { + public BasePage(boolean hasNext, List items, Object response) { this.hasNext = hasNext; this.items = items; + this.response = response; } public boolean hasNext() { @@ -21,4 +24,15 @@ public boolean hasNext() { public List getItems() { return items; } + + /** + * Returns the full response object for accessing pagination metadata like cursor tokens. + * + * @return Optional containing the response, or empty if unavailable + */ + public Optional getResponse() { + @SuppressWarnings("unchecked") + R typedResponse = (R) response; + return Optional.ofNullable(typedResponse); + } } diff --git a/src/main/java/com/merge/api/core/ClientOptions.java b/src/main/java/com/merge/api/core/ClientOptions.java index 2ba818103..a14852070 100644 --- a/src/main/java/com/merge/api/core/ClientOptions.java +++ b/src/main/java/com/merge/api/core/ClientOptions.java @@ -32,10 +32,10 @@ private ClientOptions( this.headers.putAll(headers); this.headers.putAll(new HashMap() { { - put("User-Agent", "dev.merge:merge-java-client/4.0.0"); + put("User-Agent", "dev.merge:merge-java-client/5.0.0"); put("X-Fern-Language", "JAVA"); put("X-Fern-SDK-Name", "com.merge.fern:api-sdk"); - put("X-Fern-SDK-Version", "4.0.0"); + put("X-Fern-SDK-Version", "5.0.0"); } }); this.headerSuppliers = headerSuppliers; diff --git a/src/main/java/com/merge/api/core/SyncPage.java b/src/main/java/com/merge/api/core/SyncPage.java index cedb44331..ce3b65e0d 100644 --- a/src/main/java/com/merge/api/core/SyncPage.java +++ b/src/main/java/com/merge/api/core/SyncPage.java @@ -10,8 +10,8 @@ public class SyncPage extends BasePage { protected final Supplier> nextSupplier; - public SyncPage(boolean hasNext, List items, Supplier> nextSupplier) { - super(hasNext, items); + public SyncPage(boolean hasNext, List items, Object response, Supplier> nextSupplier) { + super(hasNext, items, response); this.nextSupplier = nextSupplier; } diff --git a/src/main/java/com/merge/api/core/SyncPagingIterable.java b/src/main/java/com/merge/api/core/SyncPagingIterable.java index 0726d13a2..eec1e46ec 100644 --- a/src/main/java/com/merge/api/core/SyncPagingIterable.java +++ b/src/main/java/com/merge/api/core/SyncPagingIterable.java @@ -14,12 +14,14 @@ public class SyncPagingIterable extends SyncPage implements Iterable { - public SyncPagingIterable(boolean hasNext, List items, Supplier> getNext) { - super(hasNext, items, getNext); + public SyncPagingIterable( + boolean hasNext, List items, Object response, Supplier> getNext) { + super(hasNext, items, response, getNext); } - public SyncPagingIterable(boolean hasNext, Optional> items, Supplier> getNext) { - super(hasNext, items.orElse(new ArrayList<>()), getNext); + public SyncPagingIterable( + boolean hasNext, Optional> items, Object response, Supplier> getNext) { + super(hasNext, items.orElse(new ArrayList<>()), response, getNext); } public Stream streamItems() { diff --git a/src/main/java/com/merge/api/crm/AssociationsClient.java b/src/main/java/com/merge/api/crm/AssociationsClient.java index 6ceb556db..e18cc59ca 100644 --- a/src/main/java/com/merge/api/crm/AssociationsClient.java +++ b/src/main/java/com/merge/api/crm/AssociationsClient.java @@ -67,14 +67,14 @@ public SyncPagingIterable customObjectClassesCustomObjectsAssociati * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public Association customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, - String targetObjectId) { + String targetObjectId, + String associationTypeId) { return this.rawClient .customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId) + sourceClassId, sourceObjectId, targetClassId, targetObjectId, associationTypeId) .body(); } @@ -82,15 +82,15 @@ public Association customObjectClassesCustomObjectsAssociationsUpdate( * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public Association customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request) { return this.rawClient .customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, request) + sourceClassId, sourceObjectId, targetClassId, targetObjectId, associationTypeId, request) .body(); } @@ -98,20 +98,20 @@ public Association customObjectClassesCustomObjectsAssociationsUpdate( * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public Association customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request, RequestOptions requestOptions) { return this.rawClient .customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, + associationTypeId, request, requestOptions) .body(); diff --git a/src/main/java/com/merge/api/crm/AsyncAssociationsClient.java b/src/main/java/com/merge/api/crm/AsyncAssociationsClient.java index ceb5aacab..8b1e76ce0 100644 --- a/src/main/java/com/merge/api/crm/AsyncAssociationsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncAssociationsClient.java @@ -68,14 +68,14 @@ public CompletableFuture> customObjectClassesCus * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public CompletableFuture customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, - String targetObjectId) { + String targetObjectId, + String associationTypeId) { return this.rawClient .customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId) + sourceClassId, sourceObjectId, targetClassId, targetObjectId, associationTypeId) .thenApply(response -> response.body()); } @@ -83,15 +83,15 @@ public CompletableFuture customObjectClassesCustomObjectsAssociatio * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public CompletableFuture customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request) { return this.rawClient .customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, request) + sourceClassId, sourceObjectId, targetClassId, targetObjectId, associationTypeId, request) .thenApply(response -> response.body()); } @@ -99,20 +99,20 @@ public CompletableFuture customObjectClassesCustomObjectsAssociatio * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public CompletableFuture customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request, RequestOptions requestOptions) { return this.rawClient .customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, + associationTypeId, request, requestOptions) .thenApply(response -> response.body()); diff --git a/src/main/java/com/merge/api/crm/AsyncRawAccountsClient.java b/src/main/java/com/merge/api/crm/AsyncRawAccountsClient.java index d1d9596e2..c51dff5e6 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawAccountsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawAccountsClient.java @@ -161,15 +161,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -638,15 +639,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawAssociationTypesClient.java b/src/main/java/com/merge/api/crm/AsyncRawAssociationTypesClient.java index dc1c590b1..beab1a28b 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawAssociationTypesClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawAssociationTypesClient.java @@ -154,16 +154,17 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return customObjectClassesAssociationTypesList( - customObjectClassId, nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return customObjectClassesAssociationTypesList( + customObjectClassId, nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawAssociationsClient.java b/src/main/java/com/merge/api/crm/AsyncRawAssociationsClient.java index 9500a5989..08b90b43d 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawAssociationsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawAssociationsClient.java @@ -161,16 +161,20 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return customObjectClassesCustomObjectsAssociationsList( - customObjectClassId, objectId, nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return customObjectClassesCustomObjectsAssociationsList( + customObjectClassId, + objectId, + nextRequest, + requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -198,17 +202,17 @@ public void onFailure(@NotNull Call call, @NotNull IOException e) { * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public CompletableFuture> customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, - String targetObjectId) { + String targetObjectId, + String associationTypeId) { return customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, + associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest.builder() .build()); } @@ -217,25 +221,25 @@ public CompletableFuture> customObjectClassesC * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public CompletableFuture> customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request) { return customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, request, null); + sourceClassId, sourceObjectId, targetClassId, targetObjectId, associationTypeId, request, null); } /** * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public CompletableFuture> customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request, RequestOptions requestOptions) { HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl()) diff --git a/src/main/java/com/merge/api/crm/AsyncRawAuditTrailClient.java b/src/main/java/com/merge/api/crm/AsyncRawAuditTrailClient.java index f2e769166..53b38fa9f 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawAuditTrailClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawAuditTrailClient.java @@ -109,15 +109,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawContactsClient.java b/src/main/java/com/merge/api/crm/AsyncRawContactsClient.java index 6784b1c04..d935f6c05 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawContactsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawContactsClient.java @@ -167,15 +167,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -708,15 +709,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawCustomObjectClassesClient.java b/src/main/java/com/merge/api/crm/AsyncRawCustomObjectClassesClient.java index a32d2f47a..68b136500 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawCustomObjectClassesClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawCustomObjectClassesClient.java @@ -138,15 +138,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawCustomObjectsClient.java b/src/main/java/com/merge/api/crm/AsyncRawCustomObjectsClient.java index b3af57e0c..2264b659a 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawCustomObjectsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawCustomObjectsClient.java @@ -159,16 +159,17 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return customObjectClassesCustomObjectsList( - customObjectClassId, nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return customObjectClassesCustomObjectsList( + customObjectClassId, nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -523,16 +524,17 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return customObjectClassesCustomObjectsRemoteFieldClassesList( - nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return customObjectClassesCustomObjectsRemoteFieldClassesList( + nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawEngagementTypesClient.java b/src/main/java/com/merge/api/crm/AsyncRawEngagementTypesClient.java index 5445ebcdc..dff80dc76 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawEngagementTypesClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawEngagementTypesClient.java @@ -143,15 +143,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -354,15 +355,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawEngagementsClient.java b/src/main/java/com/merge/api/crm/AsyncRawEngagementsClient.java index f1554327c..da565cdae 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawEngagementsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawEngagementsClient.java @@ -162,15 +162,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -640,15 +641,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawIssuesClient.java b/src/main/java/com/merge/api/crm/AsyncRawIssuesClient.java index 1d126ca01..6664ce786 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawIssuesClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawIssuesClient.java @@ -155,7 +155,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/crm/AsyncRawLeadsClient.java b/src/main/java/com/merge/api/crm/AsyncRawLeadsClient.java index d14cf0d96..2a17e84bd 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawLeadsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawLeadsClient.java @@ -178,7 +178,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() @@ -520,15 +520,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawLinkedAccountsClient.java b/src/main/java/com/merge/api/crm/AsyncRawLinkedAccountsClient.java index 98443ef2b..8ad5103f9 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawLinkedAccountsClient.java @@ -150,7 +150,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> { + startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/crm/AsyncRawNotesClient.java b/src/main/java/com/merge/api/crm/AsyncRawNotesClient.java index d3467f15a..d17fdcf02 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawNotesClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawNotesClient.java @@ -168,7 +168,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() @@ -510,15 +510,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawOpportunitiesClient.java b/src/main/java/com/merge/api/crm/AsyncRawOpportunitiesClient.java index 5f054c044..5b02267ac 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawOpportunitiesClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawOpportunitiesClient.java @@ -185,15 +185,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -672,15 +673,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawStagesClient.java b/src/main/java/com/merge/api/crm/AsyncRawStagesClient.java index f588ca977..f1e513823 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawStagesClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawStagesClient.java @@ -141,7 +141,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() @@ -349,15 +349,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawTasksClient.java b/src/main/java/com/merge/api/crm/AsyncRawTasksClient.java index cdffb5dde..10eb4a530 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawTasksClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawTasksClient.java @@ -153,7 +153,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() @@ -629,15 +629,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/AsyncRawUsersClient.java b/src/main/java/com/merge/api/crm/AsyncRawUsersClient.java index 7ef024eac..4f5137d1a 100644 --- a/src/main/java/com/merge/api/crm/AsyncRawUsersClient.java +++ b/src/main/java/com/merge/api/crm/AsyncRawUsersClient.java @@ -149,7 +149,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() @@ -421,15 +421,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/crm/RawAccountsClient.java b/src/main/java/com/merge/api/crm/RawAccountsClient.java index bf40199d0..8518571ac 100644 --- a/src/main/java/com/merge/api/crm/RawAccountsClient.java +++ b/src/main/java/com/merge/api/crm/RawAccountsClient.java @@ -153,9 +153,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -538,7 +538,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawAssociationTypesClient.java b/src/main/java/com/merge/api/crm/RawAssociationTypesClient.java index 9b4322f66..4ad0b8875 100644 --- a/src/main/java/com/merge/api/crm/RawAssociationTypesClient.java +++ b/src/main/java/com/merge/api/crm/RawAssociationTypesClient.java @@ -144,7 +144,10 @@ public MergeApiHttpResponse> customObjectCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> customObjectClassesAssociationTypesList( + startingAfter.isPresent(), + result, + parsedResponse, + () -> customObjectClassesAssociationTypesList( customObjectClassId, nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawAssociationsClient.java b/src/main/java/com/merge/api/crm/RawAssociationsClient.java index b9dbfeaba..5a481d89c 100644 --- a/src/main/java/com/merge/api/crm/RawAssociationsClient.java +++ b/src/main/java/com/merge/api/crm/RawAssociationsClient.java @@ -154,6 +154,7 @@ public MergeApiHttpResponse> customObjectClasses new SyncPagingIterable( startingAfter.isPresent(), result, + parsedResponse, () -> customObjectClassesCustomObjectsAssociationsList( customObjectClassId, objectId, nextRequest, requestOptions) .body()), @@ -174,17 +175,17 @@ public MergeApiHttpResponse> customObjectClasses * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public MergeApiHttpResponse customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, - String targetObjectId) { + String targetObjectId, + String associationTypeId) { return customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, + associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest.builder() .build()); } @@ -193,25 +194,25 @@ public MergeApiHttpResponse customObjectClassesCustomObjectsAssocia * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public MergeApiHttpResponse customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request) { return customObjectClassesCustomObjectsAssociationsUpdate( - associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, request, null); + sourceClassId, sourceObjectId, targetClassId, targetObjectId, associationTypeId, request, null); } /** * Creates an Association between source_object_id and target_object_id of type association_type_id. */ public MergeApiHttpResponse customObjectClassesCustomObjectsAssociationsUpdate( - String associationTypeId, String sourceClassId, String sourceObjectId, String targetClassId, String targetObjectId, + String associationTypeId, CustomObjectClassesCustomObjectsAssociationsUpdateRequest request, RequestOptions requestOptions) { HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl()) diff --git a/src/main/java/com/merge/api/crm/RawAuditTrailClient.java b/src/main/java/com/merge/api/crm/RawAuditTrailClient.java index 9376c2d7c..326d3aebb 100644 --- a/src/main/java/com/merge/api/crm/RawAuditTrailClient.java +++ b/src/main/java/com/merge/api/crm/RawAuditTrailClient.java @@ -101,7 +101,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/crm/RawContactsClient.java b/src/main/java/com/merge/api/crm/RawContactsClient.java index 9a63850fd..f8583b71f 100644 --- a/src/main/java/com/merge/api/crm/RawContactsClient.java +++ b/src/main/java/com/merge/api/crm/RawContactsClient.java @@ -159,9 +159,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -594,7 +594,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawCustomObjectClassesClient.java b/src/main/java/com/merge/api/crm/RawCustomObjectClassesClient.java index d7424dced..db7d844f2 100644 --- a/src/main/java/com/merge/api/crm/RawCustomObjectClassesClient.java +++ b/src/main/java/com/merge/api/crm/RawCustomObjectClassesClient.java @@ -128,7 +128,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/crm/RawCustomObjectsClient.java b/src/main/java/com/merge/api/crm/RawCustomObjectsClient.java index 2a38f4c17..b43534cb2 100644 --- a/src/main/java/com/merge/api/crm/RawCustomObjectsClient.java +++ b/src/main/java/com/merge/api/crm/RawCustomObjectsClient.java @@ -150,7 +150,10 @@ public MergeApiHttpResponse> customObjectClasse List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> customObjectClassesCustomObjectsList( + startingAfter.isPresent(), + result, + parsedResponse, + () -> customObjectClassesCustomObjectsList( customObjectClassId, nextRequest, requestOptions) .body()), response); @@ -453,6 +456,7 @@ public MergeApiHttpResponse customObjectClassesCustomObjectsMetaPo new SyncPagingIterable( startingAfter.isPresent(), result, + parsedResponse, () -> customObjectClassesCustomObjectsRemoteFieldClassesList( nextRequest, requestOptions) .body()), diff --git a/src/main/java/com/merge/api/crm/RawEngagementTypesClient.java b/src/main/java/com/merge/api/crm/RawEngagementTypesClient.java index 7a7739822..e127644cc 100644 --- a/src/main/java/com/merge/api/crm/RawEngagementTypesClient.java +++ b/src/main/java/com/merge/api/crm/RawEngagementTypesClient.java @@ -134,7 +134,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } @@ -309,7 +310,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawEngagementsClient.java b/src/main/java/com/merge/api/crm/RawEngagementsClient.java index 645d2d18f..40b6e4a90 100644 --- a/src/main/java/com/merge/api/crm/RawEngagementsClient.java +++ b/src/main/java/com/merge/api/crm/RawEngagementsClient.java @@ -154,7 +154,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } @@ -539,7 +540,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawIssuesClient.java b/src/main/java/com/merge/api/crm/RawIssuesClient.java index 472ea84bf..822473fd5 100644 --- a/src/main/java/com/merge/api/crm/RawIssuesClient.java +++ b/src/main/java/com/merge/api/crm/RawIssuesClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/crm/RawLeadsClient.java b/src/main/java/com/merge/api/crm/RawLeadsClient.java index 83c89a1d0..37a53a460 100644 --- a/src/main/java/com/merge/api/crm/RawLeadsClient.java +++ b/src/main/java/com/merge/api/crm/RawLeadsClient.java @@ -170,9 +170,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -449,7 +449,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawLinkedAccountsClient.java b/src/main/java/com/merge/api/crm/RawLinkedAccountsClient.java index d92ca63a3..8896a07d7 100644 --- a/src/main/java/com/merge/api/crm/RawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/crm/RawLinkedAccountsClient.java @@ -140,7 +140,8 @@ public MergeApiHttpResponse> list( parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/crm/RawNotesClient.java b/src/main/java/com/merge/api/crm/RawNotesClient.java index dae4907d2..bc3f772e8 100644 --- a/src/main/java/com/merge/api/crm/RawNotesClient.java +++ b/src/main/java/com/merge/api/crm/RawNotesClient.java @@ -160,9 +160,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -439,7 +439,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawOpportunitiesClient.java b/src/main/java/com/merge/api/crm/RawOpportunitiesClient.java index c05e8112a..fabefdb7b 100644 --- a/src/main/java/com/merge/api/crm/RawOpportunitiesClient.java +++ b/src/main/java/com/merge/api/crm/RawOpportunitiesClient.java @@ -177,7 +177,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } @@ -573,7 +574,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawStagesClient.java b/src/main/java/com/merge/api/crm/RawStagesClient.java index 8a3c203a9..559619059 100644 --- a/src/main/java/com/merge/api/crm/RawStagesClient.java +++ b/src/main/java/com/merge/api/crm/RawStagesClient.java @@ -133,9 +133,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -308,7 +308,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawTasksClient.java b/src/main/java/com/merge/api/crm/RawTasksClient.java index 1f5d62a82..26e683c50 100644 --- a/src/main/java/com/merge/api/crm/RawTasksClient.java +++ b/src/main/java/com/merge/api/crm/RawTasksClient.java @@ -145,9 +145,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -528,7 +528,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/RawUsersClient.java b/src/main/java/com/merge/api/crm/RawUsersClient.java index 99eb6e894..0c0162460 100644 --- a/src/main/java/com/merge/api/crm/RawUsersClient.java +++ b/src/main/java/com/merge/api/crm/RawUsersClient.java @@ -141,9 +141,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -365,7 +365,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/crm/types/AccountDetailsAndActionsIntegration.java b/src/main/java/com/merge/api/crm/types/AccountDetailsAndActionsIntegration.java index 4f2a5b2c0..92848ab0b 100644 --- a/src/main/java/com/merge/api/crm/types/AccountDetailsAndActionsIntegration.java +++ b/src/main/java/com/merge/api/crm/types/AccountDetailsAndActionsIntegration.java @@ -309,7 +309,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/AssociationTypeRequestRequest.java b/src/main/java/com/merge/api/crm/types/AssociationTypeRequestRequest.java index 4406ad529..53666cc22 100644 --- a/src/main/java/com/merge/api/crm/types/AssociationTypeRequestRequest.java +++ b/src/main/java/com/merge/api/crm/types/AssociationTypeRequestRequest.java @@ -257,7 +257,9 @@ public _FinalStage addTargetObjectClasses(ObjectClassDescriptionRequest targetOb @JsonSetter(value = "target_object_classes", nulls = Nulls.SKIP) public _FinalStage targetObjectClasses(List targetObjectClasses) { this.targetObjectClasses.clear(); - this.targetObjectClasses.addAll(targetObjectClasses); + if (targetObjectClasses != null) { + this.targetObjectClasses.addAll(targetObjectClasses); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CommonModelScopeApi.java b/src/main/java/com/merge/api/crm/types/CommonModelScopeApi.java index 44a859dcb..7e7f466f0 100644 --- a/src/main/java/com/merge/api/crm/types/CommonModelScopeApi.java +++ b/src/main/java/com/merge/api/crm/types/CommonModelScopeApi.java @@ -88,7 +88,9 @@ public Builder from(CommonModelScopeApi other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CommonModelScopesBodyRequest.java b/src/main/java/com/merge/api/crm/types/CommonModelScopesBodyRequest.java index 1058c3727..b7a22587e 100644 --- a/src/main/java/com/merge/api/crm/types/CommonModelScopesBodyRequest.java +++ b/src/main/java/com/merge/api/crm/types/CommonModelScopesBodyRequest.java @@ -155,7 +155,9 @@ public _FinalStage addDisabledFields(String disabledFields) { @JsonSetter(value = "disabled_fields", nulls = Nulls.SKIP) public _FinalStage disabledFields(List disabledFields) { this.disabledFields.clear(); - this.disabledFields.addAll(disabledFields); + if (disabledFields != null) { + this.disabledFields.addAll(disabledFields); + } return this; } @@ -177,7 +179,9 @@ public _FinalStage addEnabledActions(EnabledActionsEnum enabledActions) { @JsonSetter(value = "enabled_actions", nulls = Nulls.SKIP) public _FinalStage enabledActions(List enabledActions) { this.enabledActions.clear(); - this.enabledActions.addAll(enabledActions); + if (enabledActions != null) { + this.enabledActions.addAll(enabledActions); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CreateFieldMappingRequest.java b/src/main/java/com/merge/api/crm/types/CreateFieldMappingRequest.java index 11aabfe99..09b623a11 100644 --- a/src/main/java/com/merge/api/crm/types/CreateFieldMappingRequest.java +++ b/src/main/java/com/merge/api/crm/types/CreateFieldMappingRequest.java @@ -342,7 +342,9 @@ public _FinalStage addRemoteFieldTraversalPath(JsonNode remoteFieldTraversalPath @JsonSetter(value = "remote_field_traversal_path", nulls = Nulls.SKIP) public _FinalStage remoteFieldTraversalPath(List remoteFieldTraversalPath) { this.remoteFieldTraversalPath.clear(); - this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + if (remoteFieldTraversalPath != null) { + this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CrmAccountResponse.java b/src/main/java/com/merge/api/crm/types/CrmAccountResponse.java index a7709bd7c..6a16a2d97 100644 --- a/src/main/java/com/merge/api/crm/types/CrmAccountResponse.java +++ b/src/main/java/com/merge/api/crm/types/CrmAccountResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CrmAssociationTypeResponse.java b/src/main/java/com/merge/api/crm/types/CrmAssociationTypeResponse.java index 26281b424..d2337b5aa 100644 --- a/src/main/java/com/merge/api/crm/types/CrmAssociationTypeResponse.java +++ b/src/main/java/com/merge/api/crm/types/CrmAssociationTypeResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CrmContactResponse.java b/src/main/java/com/merge/api/crm/types/CrmContactResponse.java index e7b3897fc..a599b0124 100644 --- a/src/main/java/com/merge/api/crm/types/CrmContactResponse.java +++ b/src/main/java/com/merge/api/crm/types/CrmContactResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CrmCustomObjectResponse.java b/src/main/java/com/merge/api/crm/types/CrmCustomObjectResponse.java index 63eef442a..3b5897c46 100644 --- a/src/main/java/com/merge/api/crm/types/CrmCustomObjectResponse.java +++ b/src/main/java/com/merge/api/crm/types/CrmCustomObjectResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/CustomObjectRequest.java b/src/main/java/com/merge/api/crm/types/CustomObjectRequest.java index fd34425de..3d13c8688 100644 --- a/src/main/java/com/merge/api/crm/types/CustomObjectRequest.java +++ b/src/main/java/com/merge/api/crm/types/CustomObjectRequest.java @@ -110,7 +110,9 @@ public Builder from(CustomObjectRequest other) { @JsonSetter(value = "fields", nulls = Nulls.SKIP) public Builder fields(Map fields) { this.fields.clear(); - this.fields.putAll(fields); + if (fields != null) { + this.fields.putAll(fields); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/EndUserDetailsRequest.java b/src/main/java/com/merge/api/crm/types/EndUserDetailsRequest.java index f657e0948..d9055f594 100644 --- a/src/main/java/com/merge/api/crm/types/EndUserDetailsRequest.java +++ b/src/main/java/com/merge/api/crm/types/EndUserDetailsRequest.java @@ -663,7 +663,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/EngagementResponse.java b/src/main/java/com/merge/api/crm/types/EngagementResponse.java index 71e4c956d..d21c73c4c 100644 --- a/src/main/java/com/merge/api/crm/types/EngagementResponse.java +++ b/src/main/java/com/merge/api/crm/types/EngagementResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/FieldMappingInstanceResponse.java b/src/main/java/com/merge/api/crm/types/FieldMappingInstanceResponse.java index ec3121543..41d9217dd 100644 --- a/src/main/java/com/merge/api/crm/types/FieldMappingInstanceResponse.java +++ b/src/main/java/com/merge/api/crm/types/FieldMappingInstanceResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/LeadResponse.java b/src/main/java/com/merge/api/crm/types/LeadResponse.java index f77e20d2e..fabd47bda 100644 --- a/src/main/java/com/merge/api/crm/types/LeadResponse.java +++ b/src/main/java/com/merge/api/crm/types/LeadResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/LinkedAccountCommonModelScopeDeserializerRequest.java b/src/main/java/com/merge/api/crm/types/LinkedAccountCommonModelScopeDeserializerRequest.java index 10e19313d..0c614dcc7 100644 --- a/src/main/java/com/merge/api/crm/types/LinkedAccountCommonModelScopeDeserializerRequest.java +++ b/src/main/java/com/merge/api/crm/types/LinkedAccountCommonModelScopeDeserializerRequest.java @@ -90,7 +90,9 @@ public Builder from(LinkedAccountCommonModelScopeDeserializerRequest other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/MetaResponse.java b/src/main/java/com/merge/api/crm/types/MetaResponse.java index 2108c8c03..b4a025e5b 100644 --- a/src/main/java/com/merge/api/crm/types/MetaResponse.java +++ b/src/main/java/com/merge/api/crm/types/MetaResponse.java @@ -226,7 +226,9 @@ public _FinalStage putAllRequestSchema(Map requestSchema) { @JsonSetter(value = "request_schema", nulls = Nulls.SKIP) public _FinalStage requestSchema(Map requestSchema) { this.requestSchema.clear(); - this.requestSchema.putAll(requestSchema); + if (requestSchema != null) { + this.requestSchema.putAll(requestSchema); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/ModelOperation.java b/src/main/java/com/merge/api/crm/types/ModelOperation.java index a1a1a3b88..1a217f056 100644 --- a/src/main/java/com/merge/api/crm/types/ModelOperation.java +++ b/src/main/java/com/merge/api/crm/types/ModelOperation.java @@ -175,7 +175,9 @@ public _FinalStage addSupportedFields(String supportedFields) { @JsonSetter(value = "supported_fields", nulls = Nulls.SKIP) public _FinalStage supportedFields(List supportedFields) { this.supportedFields.clear(); - this.supportedFields.addAll(supportedFields); + if (supportedFields != null) { + this.supportedFields.addAll(supportedFields); + } return this; } @@ -197,7 +199,9 @@ public _FinalStage addRequiredPostParameters(String requiredPostParameters) { @JsonSetter(value = "required_post_parameters", nulls = Nulls.SKIP) public _FinalStage requiredPostParameters(List requiredPostParameters) { this.requiredPostParameters.clear(); - this.requiredPostParameters.addAll(requiredPostParameters); + if (requiredPostParameters != null) { + this.requiredPostParameters.addAll(requiredPostParameters); + } return this; } @@ -219,7 +223,9 @@ public _FinalStage addAvailableOperations(String availableOperations) { @JsonSetter(value = "available_operations", nulls = Nulls.SKIP) public _FinalStage availableOperations(List availableOperations) { this.availableOperations.clear(); - this.availableOperations.addAll(availableOperations); + if (availableOperations != null) { + this.availableOperations.addAll(availableOperations); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/NoteResponse.java b/src/main/java/com/merge/api/crm/types/NoteResponse.java index d1056c928..e7b6d28b9 100644 --- a/src/main/java/com/merge/api/crm/types/NoteResponse.java +++ b/src/main/java/com/merge/api/crm/types/NoteResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/OpportunityResponse.java b/src/main/java/com/merge/api/crm/types/OpportunityResponse.java index 8cd070dcd..50e8f65e8 100644 --- a/src/main/java/com/merge/api/crm/types/OpportunityResponse.java +++ b/src/main/java/com/merge/api/crm/types/OpportunityResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/RemoteEndpointInfo.java b/src/main/java/com/merge/api/crm/types/RemoteEndpointInfo.java index 4cd00bb24..853d32eb6 100644 --- a/src/main/java/com/merge/api/crm/types/RemoteEndpointInfo.java +++ b/src/main/java/com/merge/api/crm/types/RemoteEndpointInfo.java @@ -161,7 +161,9 @@ public _FinalStage addFieldTraversalPath(JsonNode fieldTraversalPath) { @JsonSetter(value = "field_traversal_path", nulls = Nulls.SKIP) public _FinalStage fieldTraversalPath(List fieldTraversalPath) { this.fieldTraversalPath.clear(); - this.fieldTraversalPath.addAll(fieldTraversalPath); + if (fieldTraversalPath != null) { + this.fieldTraversalPath.addAll(fieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/RemoteFieldApi.java b/src/main/java/com/merge/api/crm/types/RemoteFieldApi.java index e692598de..847a6378e 100644 --- a/src/main/java/com/merge/api/crm/types/RemoteFieldApi.java +++ b/src/main/java/com/merge/api/crm/types/RemoteFieldApi.java @@ -258,7 +258,9 @@ public _FinalStage putAllSchema(Map schema) { @JsonSetter(value = "schema", nulls = Nulls.SKIP) public _FinalStage schema(Map schema) { this.schema.clear(); - this.schema.putAll(schema); + if (schema != null) { + this.schema.putAll(schema); + } return this; } diff --git a/src/main/java/com/merge/api/crm/types/TaskResponse.java b/src/main/java/com/merge/api/crm/types/TaskResponse.java index 1c04abf9b..02c96f2de 100644 --- a/src/main/java/com/merge/api/crm/types/TaskResponse.java +++ b/src/main/java/com/merge/api/crm/types/TaskResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawAuditTrailClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawAuditTrailClient.java index fe0eb920a..7deda98e4 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawAuditTrailClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawAuditTrailClient.java @@ -109,15 +109,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawDrivesClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawDrivesClient.java index c31e8e9a9..165bf7e3c 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawDrivesClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawDrivesClient.java @@ -135,7 +135,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawFilesClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawFilesClient.java index a026f4ad0..7f853f20d 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawFilesClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawFilesClient.java @@ -169,7 +169,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() @@ -588,15 +588,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return downloadRequestMetaList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return downloadRequestMetaList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawFoldersClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawFoldersClient.java index ec254ac0e..5baddd10b 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawFoldersClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawFoldersClient.java @@ -154,15 +154,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawGroupsClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawGroupsClient.java index ec91e62a4..6ca9a1089 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawGroupsClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawGroupsClient.java @@ -135,7 +135,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawIssuesClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawIssuesClient.java index 156b949f1..3d298ab44 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawIssuesClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawIssuesClient.java @@ -155,7 +155,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawLinkedAccountsClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawLinkedAccountsClient.java index c1ca2c970..7b5468283 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawLinkedAccountsClient.java @@ -150,7 +150,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> { + startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawSyncStatusClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawSyncStatusClient.java index d26cf6ccf..df18cb20b 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawSyncStatusClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawSyncStatusClient.java @@ -92,15 +92,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/filestorage/AsyncRawUsersClient.java b/src/main/java/com/merge/api/filestorage/AsyncRawUsersClient.java index 7e73d25ca..e48bd6af5 100644 --- a/src/main/java/com/merge/api/filestorage/AsyncRawUsersClient.java +++ b/src/main/java/com/merge/api/filestorage/AsyncRawUsersClient.java @@ -135,7 +135,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/filestorage/RawAuditTrailClient.java b/src/main/java/com/merge/api/filestorage/RawAuditTrailClient.java index 71a712597..e0fccd1b1 100644 --- a/src/main/java/com/merge/api/filestorage/RawAuditTrailClient.java +++ b/src/main/java/com/merge/api/filestorage/RawAuditTrailClient.java @@ -101,7 +101,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/filestorage/RawDrivesClient.java b/src/main/java/com/merge/api/filestorage/RawDrivesClient.java index f6dac33ac..c0859de30 100644 --- a/src/main/java/com/merge/api/filestorage/RawDrivesClient.java +++ b/src/main/java/com/merge/api/filestorage/RawDrivesClient.java @@ -127,9 +127,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/filestorage/RawFilesClient.java b/src/main/java/com/merge/api/filestorage/RawFilesClient.java index 23081da39..4fb34a6e5 100644 --- a/src/main/java/com/merge/api/filestorage/RawFilesClient.java +++ b/src/main/java/com/merge/api/filestorage/RawFilesClient.java @@ -161,9 +161,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -504,7 +504,7 @@ public MergeApiHttpResponse> downloadReq List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> downloadRequestMetaList( + startingAfter.isPresent(), result, parsedResponse, () -> downloadRequestMetaList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/filestorage/RawFoldersClient.java b/src/main/java/com/merge/api/filestorage/RawFoldersClient.java index 5ecccb449..3d09fd355 100644 --- a/src/main/java/com/merge/api/filestorage/RawFoldersClient.java +++ b/src/main/java/com/merge/api/filestorage/RawFoldersClient.java @@ -146,9 +146,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/filestorage/RawGroupsClient.java b/src/main/java/com/merge/api/filestorage/RawGroupsClient.java index ce4f01f30..86f67c14f 100644 --- a/src/main/java/com/merge/api/filestorage/RawGroupsClient.java +++ b/src/main/java/com/merge/api/filestorage/RawGroupsClient.java @@ -127,9 +127,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/filestorage/RawIssuesClient.java b/src/main/java/com/merge/api/filestorage/RawIssuesClient.java index 74abd7f49..7eaccfd09 100644 --- a/src/main/java/com/merge/api/filestorage/RawIssuesClient.java +++ b/src/main/java/com/merge/api/filestorage/RawIssuesClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/filestorage/RawLinkedAccountsClient.java b/src/main/java/com/merge/api/filestorage/RawLinkedAccountsClient.java index 2e51add7b..0fe590c8d 100644 --- a/src/main/java/com/merge/api/filestorage/RawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/filestorage/RawLinkedAccountsClient.java @@ -140,7 +140,8 @@ public MergeApiHttpResponse> list( parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/filestorage/RawSyncStatusClient.java b/src/main/java/com/merge/api/filestorage/RawSyncStatusClient.java index 0cf0dd0ed..44d7fe9fd 100644 --- a/src/main/java/com/merge/api/filestorage/RawSyncStatusClient.java +++ b/src/main/java/com/merge/api/filestorage/RawSyncStatusClient.java @@ -85,7 +85,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/filestorage/RawUsersClient.java b/src/main/java/com/merge/api/filestorage/RawUsersClient.java index a81fa00d0..282b07cb5 100644 --- a/src/main/java/com/merge/api/filestorage/RawUsersClient.java +++ b/src/main/java/com/merge/api/filestorage/RawUsersClient.java @@ -127,9 +127,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/filestorage/types/AccountDetailsAndActionsIntegration.java b/src/main/java/com/merge/api/filestorage/types/AccountDetailsAndActionsIntegration.java index 495b78d16..43eb5e973 100644 --- a/src/main/java/com/merge/api/filestorage/types/AccountDetailsAndActionsIntegration.java +++ b/src/main/java/com/merge/api/filestorage/types/AccountDetailsAndActionsIntegration.java @@ -309,7 +309,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/CommonModelScopeApi.java b/src/main/java/com/merge/api/filestorage/types/CommonModelScopeApi.java index a836ab738..bf4064668 100644 --- a/src/main/java/com/merge/api/filestorage/types/CommonModelScopeApi.java +++ b/src/main/java/com/merge/api/filestorage/types/CommonModelScopeApi.java @@ -88,7 +88,9 @@ public Builder from(CommonModelScopeApi other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/CommonModelScopesBodyRequest.java b/src/main/java/com/merge/api/filestorage/types/CommonModelScopesBodyRequest.java index 46d76db0f..626bdc2c3 100644 --- a/src/main/java/com/merge/api/filestorage/types/CommonModelScopesBodyRequest.java +++ b/src/main/java/com/merge/api/filestorage/types/CommonModelScopesBodyRequest.java @@ -155,7 +155,9 @@ public _FinalStage addDisabledFields(String disabledFields) { @JsonSetter(value = "disabled_fields", nulls = Nulls.SKIP) public _FinalStage disabledFields(List disabledFields) { this.disabledFields.clear(); - this.disabledFields.addAll(disabledFields); + if (disabledFields != null) { + this.disabledFields.addAll(disabledFields); + } return this; } @@ -177,7 +179,9 @@ public _FinalStage addEnabledActions(EnabledActionsEnum enabledActions) { @JsonSetter(value = "enabled_actions", nulls = Nulls.SKIP) public _FinalStage enabledActions(List enabledActions) { this.enabledActions.clear(); - this.enabledActions.addAll(enabledActions); + if (enabledActions != null) { + this.enabledActions.addAll(enabledActions); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/CreateFieldMappingRequest.java b/src/main/java/com/merge/api/filestorage/types/CreateFieldMappingRequest.java index 763248d87..26291d48c 100644 --- a/src/main/java/com/merge/api/filestorage/types/CreateFieldMappingRequest.java +++ b/src/main/java/com/merge/api/filestorage/types/CreateFieldMappingRequest.java @@ -342,7 +342,9 @@ public _FinalStage addRemoteFieldTraversalPath(JsonNode remoteFieldTraversalPath @JsonSetter(value = "remote_field_traversal_path", nulls = Nulls.SKIP) public _FinalStage remoteFieldTraversalPath(List remoteFieldTraversalPath) { this.remoteFieldTraversalPath.clear(); - this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + if (remoteFieldTraversalPath != null) { + this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/DownloadRequestMeta.java b/src/main/java/com/merge/api/filestorage/types/DownloadRequestMeta.java index 0f046d258..4d59f0efa 100644 --- a/src/main/java/com/merge/api/filestorage/types/DownloadRequestMeta.java +++ b/src/main/java/com/merge/api/filestorage/types/DownloadRequestMeta.java @@ -184,7 +184,9 @@ public _FinalStage putAllHeaders(Map headers) { @JsonSetter(value = "headers", nulls = Nulls.SKIP) public _FinalStage headers(Map headers) { this.headers.clear(); - this.headers.putAll(headers); + if (headers != null) { + this.headers.putAll(headers); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/EndUserDetailsRequest.java b/src/main/java/com/merge/api/filestorage/types/EndUserDetailsRequest.java index 169e1a578..be0863dff 100644 --- a/src/main/java/com/merge/api/filestorage/types/EndUserDetailsRequest.java +++ b/src/main/java/com/merge/api/filestorage/types/EndUserDetailsRequest.java @@ -663,7 +663,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/FieldMappingInstanceResponse.java b/src/main/java/com/merge/api/filestorage/types/FieldMappingInstanceResponse.java index fdce30e9b..e2f745d0d 100644 --- a/src/main/java/com/merge/api/filestorage/types/FieldMappingInstanceResponse.java +++ b/src/main/java/com/merge/api/filestorage/types/FieldMappingInstanceResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/FileStorageFileResponse.java b/src/main/java/com/merge/api/filestorage/types/FileStorageFileResponse.java index 4d30de5f8..f4eac13ae 100644 --- a/src/main/java/com/merge/api/filestorage/types/FileStorageFileResponse.java +++ b/src/main/java/com/merge/api/filestorage/types/FileStorageFileResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/FileStorageFolderResponse.java b/src/main/java/com/merge/api/filestorage/types/FileStorageFolderResponse.java index 21e77c2b0..12509abe6 100644 --- a/src/main/java/com/merge/api/filestorage/types/FileStorageFolderResponse.java +++ b/src/main/java/com/merge/api/filestorage/types/FileStorageFolderResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/Group.java b/src/main/java/com/merge/api/filestorage/types/Group.java index 7b262387c..3413fbbcb 100644 --- a/src/main/java/com/merge/api/filestorage/types/Group.java +++ b/src/main/java/com/merge/api/filestorage/types/Group.java @@ -304,7 +304,9 @@ public Builder name(String name) { @JsonSetter(value = "users", nulls = Nulls.SKIP) public Builder users(List users) { this.users.clear(); - this.users.addAll(users); + if (users != null) { + this.users.addAll(users); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/LinkedAccountCommonModelScopeDeserializerRequest.java b/src/main/java/com/merge/api/filestorage/types/LinkedAccountCommonModelScopeDeserializerRequest.java index 1020d718f..b71f5a1cf 100644 --- a/src/main/java/com/merge/api/filestorage/types/LinkedAccountCommonModelScopeDeserializerRequest.java +++ b/src/main/java/com/merge/api/filestorage/types/LinkedAccountCommonModelScopeDeserializerRequest.java @@ -90,7 +90,9 @@ public Builder from(LinkedAccountCommonModelScopeDeserializerRequest other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/MetaResponse.java b/src/main/java/com/merge/api/filestorage/types/MetaResponse.java index d108f3b7b..9799f6021 100644 --- a/src/main/java/com/merge/api/filestorage/types/MetaResponse.java +++ b/src/main/java/com/merge/api/filestorage/types/MetaResponse.java @@ -226,7 +226,9 @@ public _FinalStage putAllRequestSchema(Map requestSchema) { @JsonSetter(value = "request_schema", nulls = Nulls.SKIP) public _FinalStage requestSchema(Map requestSchema) { this.requestSchema.clear(); - this.requestSchema.putAll(requestSchema); + if (requestSchema != null) { + this.requestSchema.putAll(requestSchema); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/ModelOperation.java b/src/main/java/com/merge/api/filestorage/types/ModelOperation.java index 5168287d9..1bacf687d 100644 --- a/src/main/java/com/merge/api/filestorage/types/ModelOperation.java +++ b/src/main/java/com/merge/api/filestorage/types/ModelOperation.java @@ -175,7 +175,9 @@ public _FinalStage addSupportedFields(String supportedFields) { @JsonSetter(value = "supported_fields", nulls = Nulls.SKIP) public _FinalStage supportedFields(List supportedFields) { this.supportedFields.clear(); - this.supportedFields.addAll(supportedFields); + if (supportedFields != null) { + this.supportedFields.addAll(supportedFields); + } return this; } @@ -197,7 +199,9 @@ public _FinalStage addRequiredPostParameters(String requiredPostParameters) { @JsonSetter(value = "required_post_parameters", nulls = Nulls.SKIP) public _FinalStage requiredPostParameters(List requiredPostParameters) { this.requiredPostParameters.clear(); - this.requiredPostParameters.addAll(requiredPostParameters); + if (requiredPostParameters != null) { + this.requiredPostParameters.addAll(requiredPostParameters); + } return this; } @@ -219,7 +223,9 @@ public _FinalStage addAvailableOperations(String availableOperations) { @JsonSetter(value = "available_operations", nulls = Nulls.SKIP) public _FinalStage availableOperations(List availableOperations) { this.availableOperations.clear(); - this.availableOperations.addAll(availableOperations); + if (availableOperations != null) { + this.availableOperations.addAll(availableOperations); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/RemoteEndpointInfo.java b/src/main/java/com/merge/api/filestorage/types/RemoteEndpointInfo.java index 07ac8f64b..c3e792cac 100644 --- a/src/main/java/com/merge/api/filestorage/types/RemoteEndpointInfo.java +++ b/src/main/java/com/merge/api/filestorage/types/RemoteEndpointInfo.java @@ -161,7 +161,9 @@ public _FinalStage addFieldTraversalPath(JsonNode fieldTraversalPath) { @JsonSetter(value = "field_traversal_path", nulls = Nulls.SKIP) public _FinalStage fieldTraversalPath(List fieldTraversalPath) { this.fieldTraversalPath.clear(); - this.fieldTraversalPath.addAll(fieldTraversalPath); + if (fieldTraversalPath != null) { + this.fieldTraversalPath.addAll(fieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/filestorage/types/RemoteFieldApi.java b/src/main/java/com/merge/api/filestorage/types/RemoteFieldApi.java index 35f157f5c..7cb150239 100644 --- a/src/main/java/com/merge/api/filestorage/types/RemoteFieldApi.java +++ b/src/main/java/com/merge/api/filestorage/types/RemoteFieldApi.java @@ -258,7 +258,9 @@ public _FinalStage putAllSchema(Map schema) { @JsonSetter(value = "schema", nulls = Nulls.SKIP) public _FinalStage schema(Map schema) { this.schema.clear(); - this.schema.putAll(schema); + if (schema != null) { + this.schema.putAll(schema); + } return this; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawAuditTrailClient.java b/src/main/java/com/merge/api/hris/AsyncRawAuditTrailClient.java index 16d171e9d..fb44a958a 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawAuditTrailClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawAuditTrailClient.java @@ -109,15 +109,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawBankInfoClient.java b/src/main/java/com/merge/api/hris/AsyncRawBankInfoClient.java index 831eea568..d396e3788 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawBankInfoClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawBankInfoClient.java @@ -159,15 +159,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawBenefitsClient.java b/src/main/java/com/merge/api/hris/AsyncRawBenefitsClient.java index c532ec94c..b421bc017 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawBenefitsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawBenefitsClient.java @@ -139,15 +139,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawCompaniesClient.java b/src/main/java/com/merge/api/hris/AsyncRawCompaniesClient.java index a22c37f03..846e9b4f0 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawCompaniesClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawCompaniesClient.java @@ -131,15 +131,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawDependentsClient.java b/src/main/java/com/merge/api/hris/AsyncRawDependentsClient.java index d6f7223bc..8b3dccf25 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawDependentsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawDependentsClient.java @@ -138,15 +138,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawEmployeePayrollRunsClient.java b/src/main/java/com/merge/api/hris/AsyncRawEmployeePayrollRunsClient.java index 56975c987..8885dadba 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawEmployeePayrollRunsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawEmployeePayrollRunsClient.java @@ -162,15 +162,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawEmployeesClient.java b/src/main/java/com/merge/api/hris/AsyncRawEmployeesClient.java index 35617e9bf..3168b15de 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawEmployeesClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawEmployeesClient.java @@ -235,15 +235,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawEmployerBenefitsClient.java b/src/main/java/com/merge/api/hris/AsyncRawEmployerBenefitsClient.java index 7d951e2ee..d8978ab51 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawEmployerBenefitsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawEmployerBenefitsClient.java @@ -133,15 +133,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawEmploymentsClient.java b/src/main/java/com/merge/api/hris/AsyncRawEmploymentsClient.java index 83fadeb1d..86b332359 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawEmploymentsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawEmploymentsClient.java @@ -152,15 +152,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawGroupsClient.java b/src/main/java/com/merge/api/hris/AsyncRawGroupsClient.java index 0ecae3cca..6967fa665 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawGroupsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawGroupsClient.java @@ -154,7 +154,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/hris/AsyncRawIssuesClient.java b/src/main/java/com/merge/api/hris/AsyncRawIssuesClient.java index f9bab6fe8..f7e148be1 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawIssuesClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawIssuesClient.java @@ -155,7 +155,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/hris/AsyncRawLinkedAccountsClient.java b/src/main/java/com/merge/api/hris/AsyncRawLinkedAccountsClient.java index bf43871c6..854c73838 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawLinkedAccountsClient.java @@ -150,7 +150,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> { + startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/hris/AsyncRawLocationsClient.java b/src/main/java/com/merge/api/hris/AsyncRawLocationsClient.java index db58cf8ec..e5ab7a389 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawLocationsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawLocationsClient.java @@ -143,15 +143,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawPayGroupsClient.java b/src/main/java/com/merge/api/hris/AsyncRawPayGroupsClient.java index 472c3b98e..a1a43ec71 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawPayGroupsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawPayGroupsClient.java @@ -131,15 +131,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawPayrollRunsClient.java b/src/main/java/com/merge/api/hris/AsyncRawPayrollRunsClient.java index 3bb3608e8..4a42c4e9d 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawPayrollRunsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawPayrollRunsClient.java @@ -160,15 +160,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawSyncStatusClient.java b/src/main/java/com/merge/api/hris/AsyncRawSyncStatusClient.java index 831788905..c36d44efa 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawSyncStatusClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawSyncStatusClient.java @@ -92,15 +92,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawTeamsClient.java b/src/main/java/com/merge/api/hris/AsyncRawTeamsClient.java index e31bde60f..0cda15a13 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawTeamsClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawTeamsClient.java @@ -139,7 +139,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/hris/AsyncRawTimeOffBalancesClient.java b/src/main/java/com/merge/api/hris/AsyncRawTimeOffBalancesClient.java index f9b51e49b..ac346facc 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawTimeOffBalancesClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawTimeOffBalancesClient.java @@ -153,15 +153,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawTimeOffClient.java b/src/main/java/com/merge/api/hris/AsyncRawTimeOffClient.java index 0d682280a..a707636ff 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawTimeOffClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawTimeOffClient.java @@ -182,15 +182,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/AsyncRawTimesheetEntriesClient.java b/src/main/java/com/merge/api/hris/AsyncRawTimesheetEntriesClient.java index a1f0dab39..fd1099107 100644 --- a/src/main/java/com/merge/api/hris/AsyncRawTimesheetEntriesClient.java +++ b/src/main/java/com/merge/api/hris/AsyncRawTimesheetEntriesClient.java @@ -168,15 +168,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/hris/RawAuditTrailClient.java b/src/main/java/com/merge/api/hris/RawAuditTrailClient.java index 9a608b38c..16817f8f7 100644 --- a/src/main/java/com/merge/api/hris/RawAuditTrailClient.java +++ b/src/main/java/com/merge/api/hris/RawAuditTrailClient.java @@ -101,7 +101,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawBankInfoClient.java b/src/main/java/com/merge/api/hris/RawBankInfoClient.java index 7483ca370..4f73b54e5 100644 --- a/src/main/java/com/merge/api/hris/RawBankInfoClient.java +++ b/src/main/java/com/merge/api/hris/RawBankInfoClient.java @@ -151,9 +151,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawBenefitsClient.java b/src/main/java/com/merge/api/hris/RawBenefitsClient.java index e38206a63..c27e71dca 100644 --- a/src/main/java/com/merge/api/hris/RawBenefitsClient.java +++ b/src/main/java/com/merge/api/hris/RawBenefitsClient.java @@ -131,9 +131,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawCompaniesClient.java b/src/main/java/com/merge/api/hris/RawCompaniesClient.java index 0592e8591..45455a446 100644 --- a/src/main/java/com/merge/api/hris/RawCompaniesClient.java +++ b/src/main/java/com/merge/api/hris/RawCompaniesClient.java @@ -123,9 +123,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawDependentsClient.java b/src/main/java/com/merge/api/hris/RawDependentsClient.java index 7c802495c..895bad81d 100644 --- a/src/main/java/com/merge/api/hris/RawDependentsClient.java +++ b/src/main/java/com/merge/api/hris/RawDependentsClient.java @@ -130,9 +130,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawEmployeePayrollRunsClient.java b/src/main/java/com/merge/api/hris/RawEmployeePayrollRunsClient.java index 152a9c634..efe2db4fa 100644 --- a/src/main/java/com/merge/api/hris/RawEmployeePayrollRunsClient.java +++ b/src/main/java/com/merge/api/hris/RawEmployeePayrollRunsClient.java @@ -152,7 +152,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawEmployeesClient.java b/src/main/java/com/merge/api/hris/RawEmployeesClient.java index c29ff08b6..308955eb5 100644 --- a/src/main/java/com/merge/api/hris/RawEmployeesClient.java +++ b/src/main/java/com/merge/api/hris/RawEmployeesClient.java @@ -227,9 +227,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawEmployerBenefitsClient.java b/src/main/java/com/merge/api/hris/RawEmployerBenefitsClient.java index e01e2d550..63bc9bfbe 100644 --- a/src/main/java/com/merge/api/hris/RawEmployerBenefitsClient.java +++ b/src/main/java/com/merge/api/hris/RawEmployerBenefitsClient.java @@ -124,7 +124,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawEmploymentsClient.java b/src/main/java/com/merge/api/hris/RawEmploymentsClient.java index 7a2530b14..2aa345b5e 100644 --- a/src/main/java/com/merge/api/hris/RawEmploymentsClient.java +++ b/src/main/java/com/merge/api/hris/RawEmploymentsClient.java @@ -144,7 +144,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawGroupsClient.java b/src/main/java/com/merge/api/hris/RawGroupsClient.java index 367a92a3d..6dc69d9f7 100644 --- a/src/main/java/com/merge/api/hris/RawGroupsClient.java +++ b/src/main/java/com/merge/api/hris/RawGroupsClient.java @@ -146,9 +146,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawIssuesClient.java b/src/main/java/com/merge/api/hris/RawIssuesClient.java index 22e8ae3cb..1c753f97f 100644 --- a/src/main/java/com/merge/api/hris/RawIssuesClient.java +++ b/src/main/java/com/merge/api/hris/RawIssuesClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawLinkedAccountsClient.java b/src/main/java/com/merge/api/hris/RawLinkedAccountsClient.java index 49e1172ba..93d246df2 100644 --- a/src/main/java/com/merge/api/hris/RawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/hris/RawLinkedAccountsClient.java @@ -140,7 +140,8 @@ public MergeApiHttpResponse> list( parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawLocationsClient.java b/src/main/java/com/merge/api/hris/RawLocationsClient.java index 10d63fe5b..08ac35f54 100644 --- a/src/main/java/com/merge/api/hris/RawLocationsClient.java +++ b/src/main/java/com/merge/api/hris/RawLocationsClient.java @@ -135,9 +135,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawPayGroupsClient.java b/src/main/java/com/merge/api/hris/RawPayGroupsClient.java index 254018e72..6407b80b1 100644 --- a/src/main/java/com/merge/api/hris/RawPayGroupsClient.java +++ b/src/main/java/com/merge/api/hris/RawPayGroupsClient.java @@ -123,9 +123,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawPayrollRunsClient.java b/src/main/java/com/merge/api/hris/RawPayrollRunsClient.java index 27f8f3466..29d1841b5 100644 --- a/src/main/java/com/merge/api/hris/RawPayrollRunsClient.java +++ b/src/main/java/com/merge/api/hris/RawPayrollRunsClient.java @@ -152,7 +152,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawSyncStatusClient.java b/src/main/java/com/merge/api/hris/RawSyncStatusClient.java index ee92a0130..233ee3ebc 100644 --- a/src/main/java/com/merge/api/hris/RawSyncStatusClient.java +++ b/src/main/java/com/merge/api/hris/RawSyncStatusClient.java @@ -85,7 +85,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawTeamsClient.java b/src/main/java/com/merge/api/hris/RawTeamsClient.java index 7f5b5ca1c..ab0c4c26a 100644 --- a/src/main/java/com/merge/api/hris/RawTeamsClient.java +++ b/src/main/java/com/merge/api/hris/RawTeamsClient.java @@ -131,9 +131,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawTimeOffBalancesClient.java b/src/main/java/com/merge/api/hris/RawTimeOffBalancesClient.java index b6164bcac..56bb0950f 100644 --- a/src/main/java/com/merge/api/hris/RawTimeOffBalancesClient.java +++ b/src/main/java/com/merge/api/hris/RawTimeOffBalancesClient.java @@ -144,7 +144,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/RawTimeOffClient.java b/src/main/java/com/merge/api/hris/RawTimeOffClient.java index a46c801e6..7d00737d8 100644 --- a/src/main/java/com/merge/api/hris/RawTimeOffClient.java +++ b/src/main/java/com/merge/api/hris/RawTimeOffClient.java @@ -174,9 +174,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/hris/RawTimesheetEntriesClient.java b/src/main/java/com/merge/api/hris/RawTimesheetEntriesClient.java index 874cc81bc..ad3672462 100644 --- a/src/main/java/com/merge/api/hris/RawTimesheetEntriesClient.java +++ b/src/main/java/com/merge/api/hris/RawTimesheetEntriesClient.java @@ -159,7 +159,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/hris/types/AccountDetailsAndActionsIntegration.java b/src/main/java/com/merge/api/hris/types/AccountDetailsAndActionsIntegration.java index daf190eb4..9cb4eb123 100644 --- a/src/main/java/com/merge/api/hris/types/AccountDetailsAndActionsIntegration.java +++ b/src/main/java/com/merge/api/hris/types/AccountDetailsAndActionsIntegration.java @@ -309,7 +309,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/CommonModelScopeApi.java b/src/main/java/com/merge/api/hris/types/CommonModelScopeApi.java index e9c9ad658..f4a664f2b 100644 --- a/src/main/java/com/merge/api/hris/types/CommonModelScopeApi.java +++ b/src/main/java/com/merge/api/hris/types/CommonModelScopeApi.java @@ -88,7 +88,9 @@ public Builder from(CommonModelScopeApi other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/CommonModelScopesBodyRequest.java b/src/main/java/com/merge/api/hris/types/CommonModelScopesBodyRequest.java index bc9fa9a09..3e1de1dc3 100644 --- a/src/main/java/com/merge/api/hris/types/CommonModelScopesBodyRequest.java +++ b/src/main/java/com/merge/api/hris/types/CommonModelScopesBodyRequest.java @@ -155,7 +155,9 @@ public _FinalStage addDisabledFields(String disabledFields) { @JsonSetter(value = "disabled_fields", nulls = Nulls.SKIP) public _FinalStage disabledFields(List disabledFields) { this.disabledFields.clear(); - this.disabledFields.addAll(disabledFields); + if (disabledFields != null) { + this.disabledFields.addAll(disabledFields); + } return this; } @@ -177,7 +179,9 @@ public _FinalStage addEnabledActions(EnabledActionsEnum enabledActions) { @JsonSetter(value = "enabled_actions", nulls = Nulls.SKIP) public _FinalStage enabledActions(List enabledActions) { this.enabledActions.clear(); - this.enabledActions.addAll(enabledActions); + if (enabledActions != null) { + this.enabledActions.addAll(enabledActions); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/CreateFieldMappingRequest.java b/src/main/java/com/merge/api/hris/types/CreateFieldMappingRequest.java index 9fe799e27..56bf31f63 100644 --- a/src/main/java/com/merge/api/hris/types/CreateFieldMappingRequest.java +++ b/src/main/java/com/merge/api/hris/types/CreateFieldMappingRequest.java @@ -342,7 +342,9 @@ public _FinalStage addRemoteFieldTraversalPath(JsonNode remoteFieldTraversalPath @JsonSetter(value = "remote_field_traversal_path", nulls = Nulls.SKIP) public _FinalStage remoteFieldTraversalPath(List remoteFieldTraversalPath) { this.remoteFieldTraversalPath.clear(); - this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + if (remoteFieldTraversalPath != null) { + this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/EmployeeResponse.java b/src/main/java/com/merge/api/hris/types/EmployeeResponse.java index c48d0b047..5e9f963ca 100644 --- a/src/main/java/com/merge/api/hris/types/EmployeeResponse.java +++ b/src/main/java/com/merge/api/hris/types/EmployeeResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/EndUserDetailsRequest.java b/src/main/java/com/merge/api/hris/types/EndUserDetailsRequest.java index 59530ba67..eb82ea479 100644 --- a/src/main/java/com/merge/api/hris/types/EndUserDetailsRequest.java +++ b/src/main/java/com/merge/api/hris/types/EndUserDetailsRequest.java @@ -663,7 +663,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/FieldMappingInstanceResponse.java b/src/main/java/com/merge/api/hris/types/FieldMappingInstanceResponse.java index d61c87522..f38150cd2 100644 --- a/src/main/java/com/merge/api/hris/types/FieldMappingInstanceResponse.java +++ b/src/main/java/com/merge/api/hris/types/FieldMappingInstanceResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/LinkedAccountCommonModelScopeDeserializerRequest.java b/src/main/java/com/merge/api/hris/types/LinkedAccountCommonModelScopeDeserializerRequest.java index f8d7a2c0c..e4070391a 100644 --- a/src/main/java/com/merge/api/hris/types/LinkedAccountCommonModelScopeDeserializerRequest.java +++ b/src/main/java/com/merge/api/hris/types/LinkedAccountCommonModelScopeDeserializerRequest.java @@ -90,7 +90,9 @@ public Builder from(LinkedAccountCommonModelScopeDeserializerRequest other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/MetaResponse.java b/src/main/java/com/merge/api/hris/types/MetaResponse.java index 4b090c2b2..74d2a4582 100644 --- a/src/main/java/com/merge/api/hris/types/MetaResponse.java +++ b/src/main/java/com/merge/api/hris/types/MetaResponse.java @@ -226,7 +226,9 @@ public _FinalStage putAllRequestSchema(Map requestSchema) { @JsonSetter(value = "request_schema", nulls = Nulls.SKIP) public _FinalStage requestSchema(Map requestSchema) { this.requestSchema.clear(); - this.requestSchema.putAll(requestSchema); + if (requestSchema != null) { + this.requestSchema.putAll(requestSchema); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/ModelOperation.java b/src/main/java/com/merge/api/hris/types/ModelOperation.java index e93f6a1ea..4b5432733 100644 --- a/src/main/java/com/merge/api/hris/types/ModelOperation.java +++ b/src/main/java/com/merge/api/hris/types/ModelOperation.java @@ -175,7 +175,9 @@ public _FinalStage addSupportedFields(String supportedFields) { @JsonSetter(value = "supported_fields", nulls = Nulls.SKIP) public _FinalStage supportedFields(List supportedFields) { this.supportedFields.clear(); - this.supportedFields.addAll(supportedFields); + if (supportedFields != null) { + this.supportedFields.addAll(supportedFields); + } return this; } @@ -197,7 +199,9 @@ public _FinalStage addRequiredPostParameters(String requiredPostParameters) { @JsonSetter(value = "required_post_parameters", nulls = Nulls.SKIP) public _FinalStage requiredPostParameters(List requiredPostParameters) { this.requiredPostParameters.clear(); - this.requiredPostParameters.addAll(requiredPostParameters); + if (requiredPostParameters != null) { + this.requiredPostParameters.addAll(requiredPostParameters); + } return this; } @@ -219,7 +223,9 @@ public _FinalStage addAvailableOperations(String availableOperations) { @JsonSetter(value = "available_operations", nulls = Nulls.SKIP) public _FinalStage availableOperations(List availableOperations) { this.availableOperations.clear(); - this.availableOperations.addAll(availableOperations); + if (availableOperations != null) { + this.availableOperations.addAll(availableOperations); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/RemoteEndpointInfo.java b/src/main/java/com/merge/api/hris/types/RemoteEndpointInfo.java index 46e44fefd..62c38f450 100644 --- a/src/main/java/com/merge/api/hris/types/RemoteEndpointInfo.java +++ b/src/main/java/com/merge/api/hris/types/RemoteEndpointInfo.java @@ -161,7 +161,9 @@ public _FinalStage addFieldTraversalPath(JsonNode fieldTraversalPath) { @JsonSetter(value = "field_traversal_path", nulls = Nulls.SKIP) public _FinalStage fieldTraversalPath(List fieldTraversalPath) { this.fieldTraversalPath.clear(); - this.fieldTraversalPath.addAll(fieldTraversalPath); + if (fieldTraversalPath != null) { + this.fieldTraversalPath.addAll(fieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/RemoteFieldApi.java b/src/main/java/com/merge/api/hris/types/RemoteFieldApi.java index 3df9d64c2..9714f4b0e 100644 --- a/src/main/java/com/merge/api/hris/types/RemoteFieldApi.java +++ b/src/main/java/com/merge/api/hris/types/RemoteFieldApi.java @@ -258,7 +258,9 @@ public _FinalStage putAllSchema(Map schema) { @JsonSetter(value = "schema", nulls = Nulls.SKIP) public _FinalStage schema(Map schema) { this.schema.clear(); - this.schema.putAll(schema); + if (schema != null) { + this.schema.putAll(schema); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/TimeOffResponse.java b/src/main/java/com/merge/api/hris/types/TimeOffResponse.java index d5d69ba4b..56c593e9e 100644 --- a/src/main/java/com/merge/api/hris/types/TimeOffResponse.java +++ b/src/main/java/com/merge/api/hris/types/TimeOffResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/hris/types/TimesheetEntryResponse.java b/src/main/java/com/merge/api/hris/types/TimesheetEntryResponse.java index 01d220898..d3757744e 100644 --- a/src/main/java/com/merge/api/hris/types/TimesheetEntryResponse.java +++ b/src/main/java/com/merge/api/hris/types/TimesheetEntryResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawAccountsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawAccountsClient.java index aca3b47be..9a00464cd 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawAccountsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawAccountsClient.java @@ -131,15 +131,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawAttachmentsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawAttachmentsClient.java index 290af6c8e..033331375 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawAttachmentsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawAttachmentsClient.java @@ -157,15 +157,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawAuditTrailClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawAuditTrailClient.java index c625a679b..59ba55c29 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawAuditTrailClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawAuditTrailClient.java @@ -109,15 +109,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawCollectionsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawCollectionsClient.java index 30a585b09..49b6f0085 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawCollectionsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawCollectionsClient.java @@ -158,15 +158,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -270,15 +271,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return viewersList(collectionId, nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return viewersList(collectionId, nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawCommentsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawCommentsClient.java index 66a94957d..7b06ac94e 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawCommentsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawCommentsClient.java @@ -153,15 +153,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawContactsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawContactsClient.java index 06c94465a..ba47410bb 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawContactsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawContactsClient.java @@ -142,15 +142,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawIssuesClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawIssuesClient.java index ed347c588..806d4c43b 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawIssuesClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawIssuesClient.java @@ -155,7 +155,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawLinkedAccountsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawLinkedAccountsClient.java index 038d7a332..1cdf01645 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawLinkedAccountsClient.java @@ -150,7 +150,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> { + startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawProjectsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawProjectsClient.java index 5ec60cc7c..aa8519c2c 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawProjectsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawProjectsClient.java @@ -134,15 +134,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -320,7 +321,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return usersList(parentId, nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawRolesClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawRolesClient.java index 7e552c363..cc2b2c286 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawRolesClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawRolesClient.java @@ -131,7 +131,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawSyncStatusClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawSyncStatusClient.java index edfd8b20f..1bac10ee3 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawSyncStatusClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawSyncStatusClient.java @@ -92,15 +92,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawTagsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawTagsClient.java index 70932e986..281cfd46d 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawTagsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawTagsClient.java @@ -131,7 +131,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawTeamsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawTeamsClient.java index d3eb8187b..39609a03b 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawTeamsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawTeamsClient.java @@ -131,7 +131,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawTicketsClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawTicketsClient.java index 9512a1c8d..f171e5faa 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawTicketsClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawTicketsClient.java @@ -253,15 +253,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return list(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return list(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -608,15 +609,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return viewersList(ticketId, nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return viewersList(ticketId, nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } @@ -862,15 +864,16 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { - try { - return remoteFieldClassesList(nextRequest, requestOptions) - .get() - .body(); - } catch (InterruptedException | ExecutionException e) { - throw new RuntimeException(e); - } - }), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> { + try { + return remoteFieldClassesList(nextRequest, requestOptions) + .get() + .body(); + } catch (InterruptedException | ExecutionException e) { + throw new RuntimeException(e); + } + }), response)); return; } diff --git a/src/main/java/com/merge/api/ticketing/AsyncRawUsersClient.java b/src/main/java/com/merge/api/ticketing/AsyncRawUsersClient.java index cbad3447b..a0f09cbef 100644 --- a/src/main/java/com/merge/api/ticketing/AsyncRawUsersClient.java +++ b/src/main/java/com/merge/api/ticketing/AsyncRawUsersClient.java @@ -143,7 +143,7 @@ public void onResponse(@NotNull Call call, @NotNull Response response) throws IO .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); future.complete(new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> { + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> { try { return list(nextRequest, requestOptions) .get() diff --git a/src/main/java/com/merge/api/ticketing/RawAccountsClient.java b/src/main/java/com/merge/api/ticketing/RawAccountsClient.java index bf14a5ac5..824485bc6 100644 --- a/src/main/java/com/merge/api/ticketing/RawAccountsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawAccountsClient.java @@ -123,9 +123,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawAttachmentsClient.java b/src/main/java/com/merge/api/ticketing/RawAttachmentsClient.java index 44bca0daa..0fc691a0a 100644 --- a/src/main/java/com/merge/api/ticketing/RawAttachmentsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawAttachmentsClient.java @@ -149,7 +149,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ticketing/RawAuditTrailClient.java b/src/main/java/com/merge/api/ticketing/RawAuditTrailClient.java index 3eb360502..55e794ff6 100644 --- a/src/main/java/com/merge/api/ticketing/RawAuditTrailClient.java +++ b/src/main/java/com/merge/api/ticketing/RawAuditTrailClient.java @@ -101,7 +101,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ticketing/RawCollectionsClient.java b/src/main/java/com/merge/api/ticketing/RawCollectionsClient.java index 5f14e8d44..7c20c2335 100644 --- a/src/main/java/com/merge/api/ticketing/RawCollectionsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawCollectionsClient.java @@ -150,7 +150,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } @@ -242,9 +243,10 @@ public MergeApiHttpResponse> viewersList( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> viewersList( - collectionId, nextRequest, requestOptions) - .body()), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> viewersList( + collectionId, nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawCommentsClient.java b/src/main/java/com/merge/api/ticketing/RawCommentsClient.java index 83573aefc..5c8f80c89 100644 --- a/src/main/java/com/merge/api/ticketing/RawCommentsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawCommentsClient.java @@ -145,9 +145,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawContactsClient.java b/src/main/java/com/merge/api/ticketing/RawContactsClient.java index 5b632b368..e4324e9f9 100644 --- a/src/main/java/com/merge/api/ticketing/RawContactsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawContactsClient.java @@ -134,9 +134,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawIssuesClient.java b/src/main/java/com/merge/api/ticketing/RawIssuesClient.java index e8120d912..75e4f2080 100644 --- a/src/main/java/com/merge/api/ticketing/RawIssuesClient.java +++ b/src/main/java/com/merge/api/ticketing/RawIssuesClient.java @@ -147,9 +147,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawLinkedAccountsClient.java b/src/main/java/com/merge/api/ticketing/RawLinkedAccountsClient.java index bbf64e490..fb5351db3 100644 --- a/src/main/java/com/merge/api/ticketing/RawLinkedAccountsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawLinkedAccountsClient.java @@ -140,7 +140,8 @@ public MergeApiHttpResponse> list( parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ticketing/RawProjectsClient.java b/src/main/java/com/merge/api/ticketing/RawProjectsClient.java index 45e899902..c982151d7 100644 --- a/src/main/java/com/merge/api/ticketing/RawProjectsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawProjectsClient.java @@ -126,9 +126,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -279,7 +279,7 @@ public MergeApiHttpResponse> usersList( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> usersList( + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> usersList( parentId, nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/ticketing/RawRolesClient.java b/src/main/java/com/merge/api/ticketing/RawRolesClient.java index 98126902f..70138aec1 100644 --- a/src/main/java/com/merge/api/ticketing/RawRolesClient.java +++ b/src/main/java/com/merge/api/ticketing/RawRolesClient.java @@ -123,9 +123,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawSyncStatusClient.java b/src/main/java/com/merge/api/ticketing/RawSyncStatusClient.java index f25e4e5ee..9805b9a3d 100644 --- a/src/main/java/com/merge/api/ticketing/RawSyncStatusClient.java +++ b/src/main/java/com/merge/api/ticketing/RawSyncStatusClient.java @@ -85,7 +85,8 @@ public MergeApiHttpResponse> list( List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) + startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) .body()), response); } diff --git a/src/main/java/com/merge/api/ticketing/RawTagsClient.java b/src/main/java/com/merge/api/ticketing/RawTagsClient.java index 8fbb88044..97e639a08 100644 --- a/src/main/java/com/merge/api/ticketing/RawTagsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawTagsClient.java @@ -122,9 +122,9 @@ public MergeApiHttpResponse> list(TagsListRequest reques .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawTeamsClient.java b/src/main/java/com/merge/api/ticketing/RawTeamsClient.java index f87b88aa9..0a79ef5e2 100644 --- a/src/main/java/com/merge/api/ticketing/RawTeamsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawTeamsClient.java @@ -123,9 +123,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/RawTicketsClient.java b/src/main/java/com/merge/api/ticketing/RawTicketsClient.java index 9756b09ff..84921349d 100644 --- a/src/main/java/com/merge/api/ticketing/RawTicketsClient.java +++ b/src/main/java/com/merge/api/ticketing/RawTicketsClient.java @@ -245,9 +245,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -538,9 +538,10 @@ public MergeApiHttpResponse> viewersList( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable(startingAfter.isPresent(), result, () -> viewersList( - ticketId, nextRequest, requestOptions) - .body()), + new SyncPagingIterable( + startingAfter.isPresent(), result, parsedResponse, () -> viewersList( + ticketId, nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; @@ -741,7 +742,7 @@ public MergeApiHttpResponse> remoteFieldCla List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( new SyncPagingIterable( - startingAfter.isPresent(), result, () -> remoteFieldClassesList( + startingAfter.isPresent(), result, parsedResponse, () -> remoteFieldClassesList( nextRequest, requestOptions) .body()), response); diff --git a/src/main/java/com/merge/api/ticketing/RawUsersClient.java b/src/main/java/com/merge/api/ticketing/RawUsersClient.java index 92108c967..1f3a380ac 100644 --- a/src/main/java/com/merge/api/ticketing/RawUsersClient.java +++ b/src/main/java/com/merge/api/ticketing/RawUsersClient.java @@ -135,9 +135,9 @@ public MergeApiHttpResponse> list( .build(); List result = parsedResponse.getResults().orElse(Collections.emptyList()); return new MergeApiHttpResponse<>( - new SyncPagingIterable( - startingAfter.isPresent(), result, () -> list(nextRequest, requestOptions) - .body()), + new SyncPagingIterable(startingAfter.isPresent(), result, parsedResponse, () -> list( + nextRequest, requestOptions) + .body()), response); } String responseBodyString = responseBody != null ? responseBody.string() : "{}"; diff --git a/src/main/java/com/merge/api/ticketing/types/AccountDetailsAndActionsIntegration.java b/src/main/java/com/merge/api/ticketing/types/AccountDetailsAndActionsIntegration.java index 98683b2ce..f0e06d896 100644 --- a/src/main/java/com/merge/api/ticketing/types/AccountDetailsAndActionsIntegration.java +++ b/src/main/java/com/merge/api/ticketing/types/AccountDetailsAndActionsIntegration.java @@ -309,7 +309,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/CollectionsListRequest.java b/src/main/java/com/merge/api/ticketing/types/CollectionsListRequest.java index ad5d87c45..6b3ebf5e1 100644 --- a/src/main/java/com/merge/api/ticketing/types/CollectionsListRequest.java +++ b/src/main/java/com/merge/api/ticketing/types/CollectionsListRequest.java @@ -25,7 +25,7 @@ public final class CollectionsListRequest { private final Optional> expand; - private final Optional collectionType; + private final Optional collectionType; private final Optional createdAfter; @@ -57,7 +57,7 @@ public final class CollectionsListRequest { private CollectionsListRequest( Optional> expand, - Optional collectionType, + Optional collectionType, Optional createdAfter, Optional createdBefore, Optional cursor, @@ -102,7 +102,7 @@ public Optional> getExpand() { * @return If provided, will only return collections of the given type. */ @JsonProperty("collection_type") - public Optional getCollectionType() { + public Optional getCollectionType() { return collectionType; } @@ -272,7 +272,7 @@ public static Builder builder() { public static final class Builder { private Optional> expand = Optional.empty(); - private Optional collectionType = Optional.empty(); + private Optional collectionType = Optional.empty(); private Optional createdAfter = Optional.empty(); @@ -347,12 +347,12 @@ public Builder expand(String expand) { *

If provided, will only return collections of the given type.

*/ @JsonSetter(value = "collection_type", nulls = Nulls.SKIP) - public Builder collectionType(Optional collectionType) { + public Builder collectionType(Optional collectionType) { this.collectionType = collectionType; return this; } - public Builder collectionType(String collectionType) { + public Builder collectionType(CollectionsListRequestCollectionType collectionType) { this.collectionType = Optional.ofNullable(collectionType); return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/CollectionsListRequestCollectionType.java b/src/main/java/com/merge/api/ticketing/types/CollectionsListRequestCollectionType.java new file mode 100644 index 000000000..07b37fbff --- /dev/null +++ b/src/main/java/com/merge/api/ticketing/types/CollectionsListRequestCollectionType.java @@ -0,0 +1,97 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.merge.api.ticketing.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class CollectionsListRequestCollectionType { + public static final CollectionsListRequestCollectionType LIST = + new CollectionsListRequestCollectionType(Value.LIST, "LIST"); + + public static final CollectionsListRequestCollectionType EMPTY = + new CollectionsListRequestCollectionType(Value.EMPTY, ""); + + public static final CollectionsListRequestCollectionType PROJECT = + new CollectionsListRequestCollectionType(Value.PROJECT, "PROJECT"); + + private final Value value; + + private final String string; + + CollectionsListRequestCollectionType(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof CollectionsListRequestCollectionType + && this.string.equals(((CollectionsListRequestCollectionType) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case LIST: + return visitor.visitList(); + case EMPTY: + return visitor.visitEmpty(); + case PROJECT: + return visitor.visitProject(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static CollectionsListRequestCollectionType valueOf(String value) { + switch (value) { + case "LIST": + return LIST; + case "": + return EMPTY; + case "PROJECT": + return PROJECT; + default: + return new CollectionsListRequestCollectionType(Value.UNKNOWN, value); + } + } + + public enum Value { + EMPTY, + + LIST, + + PROJECT, + + UNKNOWN + } + + public interface Visitor { + T visitEmpty(); + + T visitList(); + + T visitProject(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/main/java/com/merge/api/ticketing/types/CommentResponse.java b/src/main/java/com/merge/api/ticketing/types/CommentResponse.java index 18b400823..cb48f895c 100644 --- a/src/main/java/com/merge/api/ticketing/types/CommentResponse.java +++ b/src/main/java/com/merge/api/ticketing/types/CommentResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/CommonModelScopeApi.java b/src/main/java/com/merge/api/ticketing/types/CommonModelScopeApi.java index 76b06a340..e5a193199 100644 --- a/src/main/java/com/merge/api/ticketing/types/CommonModelScopeApi.java +++ b/src/main/java/com/merge/api/ticketing/types/CommonModelScopeApi.java @@ -88,7 +88,9 @@ public Builder from(CommonModelScopeApi other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/CommonModelScopesBodyRequest.java b/src/main/java/com/merge/api/ticketing/types/CommonModelScopesBodyRequest.java index 20cc9faad..e473f2d19 100644 --- a/src/main/java/com/merge/api/ticketing/types/CommonModelScopesBodyRequest.java +++ b/src/main/java/com/merge/api/ticketing/types/CommonModelScopesBodyRequest.java @@ -155,7 +155,9 @@ public _FinalStage addDisabledFields(String disabledFields) { @JsonSetter(value = "disabled_fields", nulls = Nulls.SKIP) public _FinalStage disabledFields(List disabledFields) { this.disabledFields.clear(); - this.disabledFields.addAll(disabledFields); + if (disabledFields != null) { + this.disabledFields.addAll(disabledFields); + } return this; } @@ -177,7 +179,9 @@ public _FinalStage addEnabledActions(EnabledActionsEnum enabledActions) { @JsonSetter(value = "enabled_actions", nulls = Nulls.SKIP) public _FinalStage enabledActions(List enabledActions) { this.enabledActions.clear(); - this.enabledActions.addAll(enabledActions); + if (enabledActions != null) { + this.enabledActions.addAll(enabledActions); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/CreateFieldMappingRequest.java b/src/main/java/com/merge/api/ticketing/types/CreateFieldMappingRequest.java index 52d4cdad0..6671b2bf2 100644 --- a/src/main/java/com/merge/api/ticketing/types/CreateFieldMappingRequest.java +++ b/src/main/java/com/merge/api/ticketing/types/CreateFieldMappingRequest.java @@ -342,7 +342,9 @@ public _FinalStage addRemoteFieldTraversalPath(JsonNode remoteFieldTraversalPath @JsonSetter(value = "remote_field_traversal_path", nulls = Nulls.SKIP) public _FinalStage remoteFieldTraversalPath(List remoteFieldTraversalPath) { this.remoteFieldTraversalPath.clear(); - this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + if (remoteFieldTraversalPath != null) { + this.remoteFieldTraversalPath.addAll(remoteFieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/EndUserDetailsRequest.java b/src/main/java/com/merge/api/ticketing/types/EndUserDetailsRequest.java index fa5a5dc0e..0e902558f 100644 --- a/src/main/java/com/merge/api/ticketing/types/EndUserDetailsRequest.java +++ b/src/main/java/com/merge/api/ticketing/types/EndUserDetailsRequest.java @@ -663,7 +663,9 @@ public _FinalStage addCategories(CategoriesEnum categories) { @JsonSetter(value = "categories", nulls = Nulls.SKIP) public _FinalStage categories(List categories) { this.categories.clear(); - this.categories.addAll(categories); + if (categories != null) { + this.categories.addAll(categories); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/FieldMappingInstanceResponse.java b/src/main/java/com/merge/api/ticketing/types/FieldMappingInstanceResponse.java index 523547e66..890f2183a 100644 --- a/src/main/java/com/merge/api/ticketing/types/FieldMappingInstanceResponse.java +++ b/src/main/java/com/merge/api/ticketing/types/FieldMappingInstanceResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/LinkedAccountCommonModelScopeDeserializerRequest.java b/src/main/java/com/merge/api/ticketing/types/LinkedAccountCommonModelScopeDeserializerRequest.java index 8b0392a09..3067cebc1 100644 --- a/src/main/java/com/merge/api/ticketing/types/LinkedAccountCommonModelScopeDeserializerRequest.java +++ b/src/main/java/com/merge/api/ticketing/types/LinkedAccountCommonModelScopeDeserializerRequest.java @@ -90,7 +90,9 @@ public Builder from(LinkedAccountCommonModelScopeDeserializerRequest other) { @JsonSetter(value = "common_models", nulls = Nulls.SKIP) public Builder commonModels(List commonModels) { this.commonModels.clear(); - this.commonModels.addAll(commonModels); + if (commonModels != null) { + this.commonModels.addAll(commonModels); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/MetaResponse.java b/src/main/java/com/merge/api/ticketing/types/MetaResponse.java index aaf163668..cdc84371a 100644 --- a/src/main/java/com/merge/api/ticketing/types/MetaResponse.java +++ b/src/main/java/com/merge/api/ticketing/types/MetaResponse.java @@ -226,7 +226,9 @@ public _FinalStage putAllRequestSchema(Map requestSchema) { @JsonSetter(value = "request_schema", nulls = Nulls.SKIP) public _FinalStage requestSchema(Map requestSchema) { this.requestSchema.clear(); - this.requestSchema.putAll(requestSchema); + if (requestSchema != null) { + this.requestSchema.putAll(requestSchema); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/ModelOperation.java b/src/main/java/com/merge/api/ticketing/types/ModelOperation.java index d8a2320c4..44b25c602 100644 --- a/src/main/java/com/merge/api/ticketing/types/ModelOperation.java +++ b/src/main/java/com/merge/api/ticketing/types/ModelOperation.java @@ -175,7 +175,9 @@ public _FinalStage addSupportedFields(String supportedFields) { @JsonSetter(value = "supported_fields", nulls = Nulls.SKIP) public _FinalStage supportedFields(List supportedFields) { this.supportedFields.clear(); - this.supportedFields.addAll(supportedFields); + if (supportedFields != null) { + this.supportedFields.addAll(supportedFields); + } return this; } @@ -197,7 +199,9 @@ public _FinalStage addRequiredPostParameters(String requiredPostParameters) { @JsonSetter(value = "required_post_parameters", nulls = Nulls.SKIP) public _FinalStage requiredPostParameters(List requiredPostParameters) { this.requiredPostParameters.clear(); - this.requiredPostParameters.addAll(requiredPostParameters); + if (requiredPostParameters != null) { + this.requiredPostParameters.addAll(requiredPostParameters); + } return this; } @@ -219,7 +223,9 @@ public _FinalStage addAvailableOperations(String availableOperations) { @JsonSetter(value = "available_operations", nulls = Nulls.SKIP) public _FinalStage availableOperations(List availableOperations) { this.availableOperations.clear(); - this.availableOperations.addAll(availableOperations); + if (availableOperations != null) { + this.availableOperations.addAll(availableOperations); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/RemoteEndpointInfo.java b/src/main/java/com/merge/api/ticketing/types/RemoteEndpointInfo.java index fdbad212b..9ef507d7c 100644 --- a/src/main/java/com/merge/api/ticketing/types/RemoteEndpointInfo.java +++ b/src/main/java/com/merge/api/ticketing/types/RemoteEndpointInfo.java @@ -161,7 +161,9 @@ public _FinalStage addFieldTraversalPath(JsonNode fieldTraversalPath) { @JsonSetter(value = "field_traversal_path", nulls = Nulls.SKIP) public _FinalStage fieldTraversalPath(List fieldTraversalPath) { this.fieldTraversalPath.clear(); - this.fieldTraversalPath.addAll(fieldTraversalPath); + if (fieldTraversalPath != null) { + this.fieldTraversalPath.addAll(fieldTraversalPath); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/RemoteFieldApi.java b/src/main/java/com/merge/api/ticketing/types/RemoteFieldApi.java index 664587494..ff61299e5 100644 --- a/src/main/java/com/merge/api/ticketing/types/RemoteFieldApi.java +++ b/src/main/java/com/merge/api/ticketing/types/RemoteFieldApi.java @@ -258,7 +258,9 @@ public _FinalStage putAllSchema(Map schema) { @JsonSetter(value = "schema", nulls = Nulls.SKIP) public _FinalStage schema(Map schema) { this.schema.clear(); - this.schema.putAll(schema); + if (schema != null) { + this.schema.putAll(schema); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/TicketResponse.java b/src/main/java/com/merge/api/ticketing/types/TicketResponse.java index 4617b03c8..06b0b272e 100644 --- a/src/main/java/com/merge/api/ticketing/types/TicketResponse.java +++ b/src/main/java/com/merge/api/ticketing/types/TicketResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/TicketingAttachmentResponse.java b/src/main/java/com/merge/api/ticketing/types/TicketingAttachmentResponse.java index 687ca802a..d64042660 100644 --- a/src/main/java/com/merge/api/ticketing/types/TicketingAttachmentResponse.java +++ b/src/main/java/com/merge/api/ticketing/types/TicketingAttachmentResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/TicketingContactResponse.java b/src/main/java/com/merge/api/ticketing/types/TicketingContactResponse.java index 9a29a73a8..d47434724 100644 --- a/src/main/java/com/merge/api/ticketing/types/TicketingContactResponse.java +++ b/src/main/java/com/merge/api/ticketing/types/TicketingContactResponse.java @@ -186,7 +186,9 @@ public _FinalStage addErrors(ErrorValidationProblem errors) { @JsonSetter(value = "errors", nulls = Nulls.SKIP) public _FinalStage errors(List errors) { this.errors.clear(); - this.errors.addAll(errors); + if (errors != null) { + this.errors.addAll(errors); + } return this; } @@ -208,7 +210,9 @@ public _FinalStage addWarnings(WarningValidationProblem warnings) { @JsonSetter(value = "warnings", nulls = Nulls.SKIP) public _FinalStage warnings(List warnings) { this.warnings.clear(); - this.warnings.addAll(warnings); + if (warnings != null) { + this.warnings.addAll(warnings); + } return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/TicketsListRequest.java b/src/main/java/com/merge/api/ticketing/types/TicketsListRequest.java index 41960357c..4eb4c4e46 100644 --- a/src/main/java/com/merge/api/ticketing/types/TicketsListRequest.java +++ b/src/main/java/com/merge/api/ticketing/types/TicketsListRequest.java @@ -81,7 +81,7 @@ public final class TicketsListRequest { private final Optional showEnumOrigins; - private final Optional status; + private final Optional status; private final Optional tags; @@ -121,7 +121,7 @@ private TicketsListRequest( Optional remoteUpdatedAfter, Optional remoteUpdatedBefore, Optional showEnumOrigins, - Optional status, + Optional status, Optional tags, Optional ticketType, Optional ticketUrl, @@ -404,7 +404,7 @@ public Optional getShowEnumOrigins() { * @return If provided, will only return tickets of this status. */ @JsonProperty("status") - public Optional getStatus() { + public Optional getStatus() { return status; } @@ -586,7 +586,7 @@ public static final class Builder { private Optional showEnumOrigins = Optional.empty(); - private Optional status = Optional.empty(); + private Optional status = Optional.empty(); private Optional tags = Optional.empty(); @@ -1057,12 +1057,12 @@ public Builder showEnumOrigins(TicketsListRequestShowEnumOrigins showEnumOrigins *

If provided, will only return tickets of this status.

*/ @JsonSetter(value = "status", nulls = Nulls.SKIP) - public Builder status(Optional status) { + public Builder status(Optional status) { this.status = status; return this; } - public Builder status(String status) { + public Builder status(TicketsListRequestStatus status) { this.status = Optional.ofNullable(status); return this; } diff --git a/src/main/java/com/merge/api/ticketing/types/TicketsListRequestStatus.java b/src/main/java/com/merge/api/ticketing/types/TicketsListRequestStatus.java new file mode 100644 index 000000000..16efdc8b0 --- /dev/null +++ b/src/main/java/com/merge/api/ticketing/types/TicketsListRequestStatus.java @@ -0,0 +1,115 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.merge.api.ticketing.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class TicketsListRequestStatus { + public static final TicketsListRequestStatus CLOSED = new TicketsListRequestStatus(Value.CLOSED, "CLOSED"); + + public static final TicketsListRequestStatus IN_PROGRESS = + new TicketsListRequestStatus(Value.IN_PROGRESS, "IN_PROGRESS"); + + public static final TicketsListRequestStatus EMPTY = new TicketsListRequestStatus(Value.EMPTY, ""); + + public static final TicketsListRequestStatus OPEN = new TicketsListRequestStatus(Value.OPEN, "OPEN"); + + public static final TicketsListRequestStatus ON_HOLD = new TicketsListRequestStatus(Value.ON_HOLD, "ON_HOLD"); + + private final Value value; + + private final String string; + + TicketsListRequestStatus(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof TicketsListRequestStatus + && this.string.equals(((TicketsListRequestStatus) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case CLOSED: + return visitor.visitClosed(); + case IN_PROGRESS: + return visitor.visitInProgress(); + case EMPTY: + return visitor.visitEmpty(); + case OPEN: + return visitor.visitOpen(); + case ON_HOLD: + return visitor.visitOnHold(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static TicketsListRequestStatus valueOf(String value) { + switch (value) { + case "CLOSED": + return CLOSED; + case "IN_PROGRESS": + return IN_PROGRESS; + case "": + return EMPTY; + case "OPEN": + return OPEN; + case "ON_HOLD": + return ON_HOLD; + default: + return new TicketsListRequestStatus(Value.UNKNOWN, value); + } + } + + public enum Value { + EMPTY, + + CLOSED, + + IN_PROGRESS, + + ON_HOLD, + + OPEN, + + UNKNOWN + } + + public interface Visitor { + T visitEmpty(); + + T visitClosed(); + + T visitInProgress(); + + T visitOnHold(); + + T visitOpen(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/test/java/com/merge/api/integration/CursorPaginationIntegrationTest.java b/src/test/java/com/merge/api/integration/CursorPaginationIntegrationTest.java new file mode 100644 index 000000000..d4e824eea --- /dev/null +++ b/src/test/java/com/merge/api/integration/CursorPaginationIntegrationTest.java @@ -0,0 +1,139 @@ +package com.merge.api.integration; + +import static org.junit.jupiter.api.Assertions.*; + +import com.merge.api.MergeApiClient; +import com.merge.api.core.SyncPagingIterable; +import com.merge.api.filestorage.types.Folder; +import com.merge.api.filestorage.types.FoldersListRequest; +import com.merge.api.filestorage.types.PaginatedFolderList; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; + +public class CursorPaginationIntegrationTest { + + private MergeApiClient client; + + @BeforeEach + void setUp() { + String apiKey = System.getenv("MERGE_API_KEY_FILESTORAGE"); + String accountToken = System.getenv("MERGE_ACCOUNT_TOKEN_FILESTORAGE"); + + assertNotNull(apiKey, "MERGE_API_KEY environment variable must be set"); + assertNotNull(accountToken, "MERGE_ACCOUNT_TOKEN environment variable must be set"); + + client = MergeApiClient.builder() + .apiKey(apiKey) + .accountToken(accountToken) + .build(); + } + + @Test + void testCursorPaginationWithFileStorageFolders() { + SyncPagingIterable folders = client.fileStorage().folders().list(); + + assertNotNull(folders, "Folders list should not be null"); + + // Test that getResponse() is available and returns pagination metadata + folders.getResponse().ifPresent(response -> { + assertTrue(response instanceof PaginatedFolderList, "Response should be instance of PaginatedFolderList"); + + PaginatedFolderList paginatedResponse = (PaginatedFolderList) response; + + // Test cursor pagination metadata access + paginatedResponse.getNext().ifPresent(nextCursor -> { + assertNotNull(nextCursor, "Cursor token should be available for pagination"); + }); + + // Test that we can access results + assertNotNull(paginatedResponse.getResults(), "Results list should not be null"); + }); + + // Test iteration over paginated results + int itemCount = 0; + int pageCount = 0; + + for (Folder folder : folders) { + assertNotNull(folder, "Each folder should not be null"); + itemCount++; + + // Limit test to prevent excessive API calls + if (itemCount >= 10) { + break; + } + } + + assertTrue(itemCount >= 0, "Should have processed at least 0 items"); + } + + @Test + void testStatelessPaginationWithCursor() { + // Simulate frontend flow: get first page + SyncPagingIterable firstPage = client.fileStorage().folders().list(); + + // Get the first page response to extract cursor + firstPage.getResponse().ifPresent(response -> { + assertTrue(response instanceof PaginatedFolderList, "Response should be PaginatedFolderList"); + + PaginatedFolderList paginatedResponse = (PaginatedFolderList) response; + + // If there's a next cursor, test stateless pagination by actually using it + paginatedResponse.getNext().ifPresent(nextCursor -> { + // This demonstrates how a frontend would implement stateless pagination + // by using the cursor token from the response + assertNotNull(nextCursor, "Next cursor should be available"); + assertFalse(nextCursor.trim().isEmpty(), "Next cursor should not be empty"); + + // Frontend sends cursor back to backend for next page + FoldersListRequest secondPageRequest = + FoldersListRequest.builder().cursor(nextCursor).build(); + + // Backend fetches second page using the cursor + SyncPagingIterable secondPage = + client.fileStorage().folders().list(secondPageRequest); + + assertNotNull(secondPage, "Second page should not be null"); + + // Verify we got a valid response with results + secondPage.getResponse().ifPresent(secondResponse -> { + assertTrue( + secondResponse instanceof PaginatedFolderList, + "Second page response should be PaginatedFolderList"); + + PaginatedFolderList secondPageResponse = (PaginatedFolderList) secondResponse; + assertNotNull(secondPageResponse.getResults(), "Second page should have results"); + }); + }); + }); + } + + @Test + void testPaginationMetadataAccess() { + SyncPagingIterable folders = client.fileStorage().folders().list(); + + // Test that getResponse() provides access to full API response + assertTrue(folders.getResponse().isPresent(), "getResponse() should return the API response"); + + folders.getResponse().ifPresent(response -> { + // Verify we can cast to the expected response type + assertDoesNotThrow( + () -> { + PaginatedFolderList paginatedResponse = (PaginatedFolderList) response; + + // Test access to pagination metadata + // These fields may be Optional.empty() if no pagination is needed + paginatedResponse.getNext().ifPresent(next -> { + assertNotNull(next, "Next cursor should not be null if present"); + }); + + paginatedResponse.getPrevious().ifPresent(previous -> { + assertNotNull(previous, "Previous cursor should not be null if present"); + }); + + // At minimum, results should be accessible + assertNotNull(paginatedResponse.getResults(), "Results should always be accessible"); + }, + "Should be able to access pagination metadata"); + }); + } +}