-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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 Stripe: Add new stream (credit_notes) #24666
Source Stripe: Add new stream (credit_notes) #24666
Conversation
Hey Airbyte team, I'm not sure if I've completed all the required steps here. If not, happy to make some changes with your guidance 🙏🏻 |
Hi, @erohmensing |
@igrankova Ah, I'm referring to
from here - not sure if that changes anything.
That seems bad. Do you mean just the config used for the test syncs? We should be able to get that back from GSM. |
@erohmensing I've tried to find what scopes are selected in the OAuth app, but there's just a client ID and redirect URLs. Don't see the scopes in the settings. I've restored the LastPass password using GSM and my browser passwords storage, but I'm worrying that it's not the first time when someone deletes the test accounts creds. Is there any option to restrict delete permissions for the LP users for the shared-integration-tests folder? |
@igrankova I don't expect anything - just wanted to point out that you had mentioned explicit permissions in the original issue. Maybe you were just being extra clear about what permissions it requires, and we already request those of the user :) If you're confident that nothing else is needed to add the new stream, let's go forward - would be great if someone from your team could take a look! It looks like there are already 3 rows in our test instance, so we should be able to test the new stream in the acceptance tests
Great q, I will ask this of the team who owns this |
@erohmensing, oh! I thought that there's a problem with the tests. I see. The permissions I mentioned were added when I've created the issue and I've tried to add as more info as I can for the dev for investigation. I wasn't familiar with the API because it was a bulk issues creation according to the MLP researches. |
@erohmensing |
@archangelic this one has a lot of conflicts. Can you handle them and add the expected records? |
…edit-notes-to-stripe
class CreditNotes(IncrementalStripeStream): | ||
cursor_field = "created" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@archangelic This class should similar to this one:
airbyte/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py
Lines 240 to 257 in 5707e47
class EarlyFraudWarnings(StripeStream): | |
""" | |
API docs: https://stripe.com/docs/api/radar/early_fraud_warnings/list | |
""" | |
def request_params( | |
self, | |
stream_state: Mapping[str, Any], | |
stream_slice: Mapping[str, Any] = None, | |
next_page_token: Mapping[str, Any] = None, | |
) -> MutableMapping[str, Any]: | |
params = {} | |
if next_page_token: | |
params.update(next_page_token) | |
def path(self, **kwargs): | |
return "radar/early_fraud_warnings" |
because
CreditNotes
doesn't support incremental.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The difference is CreditNotes allow you to set the limit
parameter so you can keep that in request_params
.
This stream doesn't support incremental. |
Closed in favor of #27132 |
What
This is to add a new stream called
credit_notes
, this should solve this issueHow
streams.py
and schemasRecommended reading order
y.python
🚨 User Impact 🚨
Are there any breaking changes? What is the end result perceived by the user?
New stream
For connector PRs, use this section to explain which type of semantic versioning bump occurs as a result of the changes. Refer to our Semantic Versioning for Connectors guidelines for more information. Breaking changes to connectors must be documented by an Airbyte engineer (PR author, or reviewer for community PRs) by using the Breaking Change Release Playbook.
If there are breaking changes, please merge this PR with the 🚨🚨 emoji so changelog authors can further highlight this if needed.
Pre-merge Checklist
Expand the relevant checklist and delete the others.
New Connector
Community member or Airbyter
airbyte_secret
./gradlew :airbyte-integrations:connectors:<name>:integrationTest
.0.0.1
Dockerfile
has version0.0.1
README.md
bootstrap.md
. See description and examplesdocs/integrations/<source or destination>/<name>.md
including changelog with an entry for the initial version. See changelog exampledocs/integrations/README.md
airbyte-integrations/builds.md
Airbyter
If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.
/test connector=connectors/<name>
command is passing/publish
command described hereUpdating a connector
Community member or Airbyter
Grant edit access to maintainers (instructions)
Secrets in the connector's spec are annotated with
airbyte_secret
Unit & integration tests added and passing. Community members, please provide proof of success locally e.g: screenshot or copy-paste unit, integration, and acceptance test output. To run acceptance tests for a Python connector, follow instructions in the README. For java connectors run
./gradlew :airbyte-integrations:connectors:<name>:integrationTest
.Code reviews completed
Connector version has been incremented
Dockerfile
has updated versionDocumentation updated
README.md
bootstrap.md
. See description and examplesdocs/integrations/<source or destination>/<name>.md
with an entry for the new version. See changelog examplePR name follows PR naming conventions
Airbyter
If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.
/test connector=connectors/<name>
command is passing/publish
command described hereConnector Generator
-scaffold
in their name) have been updated with the latest scaffold by running./gradlew :airbyte-integrations:connector-templates:generator:testScaffoldTemplates
then checking in your changes