This PR introduces the ability for users to pivot out the metadata field within the respective staging models for the following source tables: charge, invoice, payment_intent, payment_method, payout, plan, refund, and subscription. To configure the metadata fields to be pivoted out a user may configure the following variables:
# dbt_project.yml
vars:
stripe__charge_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
stripe__invoice_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
stripe__payment_intent_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
stripe__payment_method_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
stripe__payout_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
stripe__plan_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
stripe__refund_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
stripe__subscription_metadata: ['the', 'list', 'of', 'property', 'fields'] # Note: this is case-SENSITIVE and must match the casing of the property as it appears in the JSON
Does this PR introduce a breaking change?
[ ] Yes (please provide breaking change details below.)
[X] No (please provide explanation how the change is non breaking below.)
This metadata pivot will be disabled by default and will not introduce a breaking change for existing stripe users.
Is this PR in response to a previously created Issue
[X] Yes, Issue #20
[ ] No
How did you test the PR changes?
- [X] CircleCi
- [ ] Other (please provide additional testing details below)
**Select which warehouse(s) were used to test the PR**
- [X] BigQuery
- [X] Redshift
- [X] Snowflake
- [ ] Postgres
- [ ] Databricks
- [ ] Other (provide details below)
**Provide an emoji that best describes your current mood**
🤘
**Feedback**
We are so excited you decided to contribute to the Fivetran community dbt package! We continue to work to improve the packages and would greatly appreciate your [feedback](https://www.surveymonkey.com/r/DQ7K7WW) on our existing dbt packages or what you'd like to see next.
Are you a current Fivetran customer?
Fivetran created PR
What change(s) does this PR introduce?
This PR introduces the ability for users to pivot out the
metadata
field within the respective staging models for the following source tables:charge
,invoice
,payment_intent
,payment_method
,payout
,plan
,refund
, andsubscription
. To configure the metadata fields to be pivoted out a user may configure the following variables:Does this PR introduce a breaking change?
This metadata pivot will be disabled by default and will not introduce a breaking change for existing stripe users.
Is this PR in response to a previously created Issue
How did you test the PR changes?
- [X] CircleCi - [ ] Other (please provide additional testing details below) **Select which warehouse(s) were used to test the PR** - [X] BigQuery - [X] Redshift - [X] Snowflake - [ ] Postgres - [ ] Databricks - [ ] Other (provide details below) **Provide an emoji that best describes your current mood** 🤘 **Feedback** We are so excited you decided to contribute to the Fivetran community dbt package! We continue to work to improve the packages and would greatly appreciate your [feedback](https://www.surveymonkey.com/r/DQ7K7WW) on our existing dbt packages or what you'd like to see next.