Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

🐛 Source Orb: fix window request for credit_ledger_entries #36036

Merged
merged 1 commit into from
Mar 13, 2024

Conversation

marcosmarxm
Copy link
Member

@marcosmarxm marcosmarxm commented Mar 13, 2024

Fix credit_ledger_entries previous version was building request with larger than 30 days. As the Orb API throws errors for these request:

“Cannot search for events in a time range greater than 30 days.”

Now the connector will create a fixed-window of 30 days based on the created_at field inside the credit_ledger_entry record, our best shot to get data from the event.

I was able to run a mock test using a single customer and also I added more information whatever the code fails now giving better idea what need to be improved.

Copy link

vercel bot commented Mar 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
airbyte-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 13, 2024 7:59pm

@octavia-squidington-iii octavia-squidington-iii added area/connectors Connector related issues area/documentation Improvements or additions to documentation connectors/source/orb labels Mar 13, 2024
@marcosmarxm marcosmarxm requested a review from alex-gron March 13, 2024 19:56
@marcosmarxm marcosmarxm changed the title 🐛 Source Orb: fix window 🐛 Source Orb: fix window request for credit_ledger_entries Mar 13, 2024
@@ -38,6 +38,10 @@ In order to capture data that has been updated after creation, please run a peri

The Orb connector should not run into Orb API limitations under normal usage. Please [create an issue](https://github.com/airbytehq/airbyte/issues) if you see any rate limit issues that are not automatically retried successfully.

:::warning
The `credit_ledger_entries` stream will now include `events` data. This upgrade uses the `created_at` timestamps from the `credits` to establish a 30-day timeframe, with the earliest `created_at` as the starting point. This restriction is set by the Orb API.
Copy link
Contributor

Choose a reason for hiding this comment

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

Small nit:
events have always been included in credit_ledger_entries. The start/end date and 30 day limit is new, though.

Copy link
Contributor

@alex-gron alex-gron left a comment

Choose a reason for hiding this comment

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

Left one comment for docs. Otherwise, looks good to me!

@marcosmarxm marcosmarxm merged commit d00a839 into master Mar 13, 2024
33 checks passed
@marcosmarxm marcosmarxm deleted the marcos/source-orb-fix-event-request branch March 13, 2024 20:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/connectors Connector related issues area/documentation Improvements or additions to documentation connectors/source/orb
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants