🐛 Source Outreach: Remove custom incremental class and use new filter syntax #55805
+121
−66
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What
Previous PR here started failing due to cdk updates: #55180
It turns out Outreach has a new filter syntax, docs here: https://developers.outreach.io/api/making-requests/#new-filter-syntax
This allows us to add the the greater than or equal logic to the request parameter name instead of in the paramater value.
Now requests look like
.com/accounts?filter[updatedAt][gte]=2017-01-01
instead of.com/accounts?filter[updatedAt]=2017-01-01..inf
This eliminates the need for the custom class or complicated injection logic in the yaml.
Also changed datetime_format to %_ms instead of %f as the api returns milliseconds and %f was causing the start date timestamp to get converted to microseconds which will error out the api request as it only goes up to miliseconds.
How
Add parameter newFilterSyntax = true, remove CustomIncrementalSync class and switch to start_time_option with field_name = filter[updatedAt][gte].
Review guide
User Impact
Currently cannot set up source with latest version as the check fails and upgrading an existing source to the latest connector version causes syncs to fail with same error.
Can this PR be safely reverted and rolled back?