diff --git a/airbyte-integrations/connectors/source-stripe/setup.py b/airbyte-integrations/connectors/source-stripe/setup.py index 759389223cce..1f93ea7550a6 100644 --- a/airbyte-integrations/connectors/source-stripe/setup.py +++ b/airbyte-integrations/connectors/source-stripe/setup.py @@ -5,7 +5,7 @@ from setuptools import find_packages, setup -MAIN_REQUIREMENTS = ["airbyte-cdk", "stripe==2.56.0", "pendulum==2.1.2"] +MAIN_REQUIREMENTS = ["airbyte-cdk==0.67", "stripe==2.56.0", "pendulum==2.1.2"] TEST_REQUIREMENTS = [ "pytest~=6.1", diff --git a/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/charges.json b/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/charges.json index 8d40077b0a4f..64144b5f1363 100644 --- a/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/charges.json +++ b/airbyte-integrations/connectors/source-stripe/source_stripe/schemas/charges.json @@ -392,24 +392,65 @@ "type": ["null", "string"] }, "refunds": { - "type": ["null", "object"], - "properties": { - "object": { - "type": ["null", "string"] - }, - "data": { - "type": ["null", "array"] - }, - "has_more": { - "type": ["null", "boolean"] - }, - "total_count": { - "type": ["null", "number"] - }, - "url": { - "type": ["null", "string"] + "anyOf": [{ + "type": ["null", "object"], + "properties": { + "object": { + "type": ["null", "string"] + }, + "data": { + "type": ["null", "array"] + }, + "has_more": { + "type": ["null", "boolean"] + }, + "total_count": { + "type": ["null", "number"] + }, + "url": { + "type": ["null", "string"] + } + } + },{ + "type": ["null", "array"], + "items": { + "type": ["null", "object"], + "additionalProperties": true, + "properties": { + "id": { + "type": ["null", "string"] + }, + "object": { + "type": ["null", "string"] + }, + "amount":{ + "type": ["null", "integer"] + }, + "balance_transaction": { + "type": ["null", "string"] + }, + "currency": { + "type": ["null", "string"] + }, + "created": { + "type": ["null", "integer"] + }, + "payment_intent": { + "type": ["null", "string"] + }, + "reason": { + "type": ["null", "string"] + }, + "receipt_number": { + "type": ["null", "string"] + }, + "statys": { + "type": ["null", "string"] + } + } } - } + } + ] }, "application_fee": { "type": ["null", "string"] diff --git a/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py b/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py index a371e3da1a60..1e60b01e52ae 100644 --- a/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py +++ b/airbyte-integrations/connectors/source-stripe/source_stripe/streams.py @@ -339,7 +339,15 @@ class Charges(IncrementalStripeStreamWithUpdates): """ API docs: https://stripe.com/docs/api/charges/list """ - event_types = ["charge.created","charge.updated"] + event_types = [ + "charge.captured", + "charge.expired", + "charge.failed", + "charge.pending", + "charge.refunded", + "charge.succeeded", + "charge.updated" + ] cursor_field = "created" def path(self, **kwargs) -> str: @@ -394,7 +402,13 @@ class Disputes(IncrementalStripeStreamWithUpdates): """ API docs: https://stripe.com/docs/api/disputes/list """ - event_types = ["charge.dispute.created", "charge.dispute.updated"] + event_types = [ + "charge.dispute.created", + "charge.dispute.updated", + "charge.dispute.closed", + "charge.dispute.funds_reinstated", + "charge.dispute.funds_withdrawn" + ] cursor_field = "created" def path(self, **kwargs):