Skip to content

Commit

Permalink
Added differential_price stream
Browse files Browse the repository at this point in the history
  • Loading branch information
pnilan committed Jan 2, 2024
1 parent 08a7015 commit 43cb3c6
Show file tree
Hide file tree
Showing 7 changed files with 114 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,19 @@
"sync_mode": "incremental",
"destination_sync_mode": "append",
"cursor_field": ["updated_at"]
},
{
"stream": {
"name": "differential_price",
"json_schema": {},
"supported_sync_modes": ["full_refresh", "incremental"],
"source_defined_cursor": true,
"default_cursor_field": ["updated_at"],
"source_defined_primary_key": [["id"]]
},
"sync_mode": "incremental",
"destination_sync_mode": "append",
"cursor_field": ["updated_at"]
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,7 @@
{"stream":"comment","data":{"id":"cmt_AzZTZgTTHaxTnJV","entity_type":"subscription","entity_id":"cbdemo_trial_sub","notes":"Test PO 0000001","added_by":"[email protected]","created_at":1674034690,"type":"user","object":"comment","custom_fields":[]},"emitted_at":1703800968925}
{"stream":"comment","data":{"id":"cmt_AzZTZgTTHbgGdKK","entity_type":"transaction","entity_id":"txn_AzZTZgTTHbgFlKJ","notes":"Test cash payment","added_by":"[email protected]","created_at":1674034862,"type":"user","object":"comment","custom_fields":[]},"emitted_at":1703800968928}
{"stream":"item_family","data":{"id":"cbdemo_pf_analytics","name":"Analytics","description":"Reporting and analytics for your business.","status":"active","resource_version":1627671463249,"updated_at":1627671463,"object":"item_family","custom_fields":[]},"emitted_at":1703880848793}
{"stream":"item_family","data":{"id":"cbdemo_pf_crm","name":"CRM","description":"Turn your leads into paying customers.","status":"active","resource_version":1627671463158,"updated_at":1627671463,"object":"item_family","custom_fields":[]},"emitted_at":1703880848797}
{"stream":"item_family","data":{"id":"cbdemo_pf_crm","name":"CRM","description":"Turn your leads into paying customers.","status":"active","resource_version":1627671463158,"updated_at":1627671463,"object":"item_family","custom_fields":[]},"emitted_at":1703880848797}
{"stream":"differential_price","data":{"id":"7748afa6-fdbe-4304-ac23-d18a17f27715","item_price_id":"cbdemo_additional-analytics-USD-yearly","parent_item_id":"cbdemo_advanced","price":200000,"status":"active","resource_version":1674032542218,"updated_at":1674032542,"created_at":1674032542,"currency_code":"USD","object":"differential_price","custom_fields":[]},"emitted_at":1704223399378}
{"stream":"differential_price","data":{"id":"7748afa6-fdbe-4304-ac23-d18a17f27715","item_price_id":"cbdemo_additional-analytics-USD-yearly","parent_item_id":"cbdemo_advanced","price":200000,"status":"active","resource_version":1674032542218,"updated_at":1674032542,"created_at":1674032542,"currency_code":"USD","object":"differential_price","custom_fields":[]},"emitted_at":1704223399498}
{"stream":"differential_price","data":{"id":"7748afa6-fdbe-4304-ac23-d18a17f27715","item_price_id":"cbdemo_additional-analytics-USD-yearly","parent_item_id":"cbdemo_advanced","price":200000,"status":"active","resource_version":1674032542218,"updated_at":1674032542,"created_at":1674032542,"currency_code":"USD","object":"differential_price","custom_fields":[]},"emitted_at":1704223399634}
Original file line number Diff line number Diff line change
Expand Up @@ -131,5 +131,12 @@
"stream_state": { "updated_at": 2147483647 },
"stream_descriptor": { "name": "item_family" }
}
},
{
"type": "STREAM",
"stream": {
"stream_state": { "updated_at": 2147483647 },
"stream_descriptor": { "name": "differential_price" }
}
}
]
Original file line number Diff line number Diff line change
Expand Up @@ -131,5 +131,12 @@
"stream_state": { "updated_at": 1625596058 },
"stream_descriptor": { "name": "item_family" }
}
},
{
"type": "STREAM",
"stream": {
"stream_state": { "updated_at": 1625596058 },
"stream_descriptor": { "name": "differential_price" }
}
}
]
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,13 @@ definitions:
primary_key: "id"
path: "/item_families"
stream_cursor_field: "updated_at"
differential_price_stream:
$ref: "#/definitions/base_incremental_stream"
$parameters:
name: "differential_price"
primary_key: "id"
path: "/differential_prices"
stream_cursor_field: "updated_at"

streams:
- "#/definitions/addon_stream"
Expand Down Expand Up @@ -383,6 +390,7 @@ streams:
- "#/definitions/site_migration_detail_stream"
- "#/definitions/comment_stream"
- "#/definitions/item_family_stream"
- "#/definitions/differential_price_stream"

check:
stream_names:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"name": "Add-on",
"type": "object",
"properties": {
"id": {
"type": ["string", "null"]
},
"item_price_id": {
"type": ["string", "null"]
},
"parent_item_id": {
"type": ["string", "null"]
},
"price": {
"type": ["integer", "null"]
},
"price_in_decimal": {
"type": ["string", "null"]
},
"status": {
"type": ["string", "null"]
},
"resource_version": {
"type": ["integer", "null"]
},
"updated_at": {
"type": ["integer", "null"]
},
"created_at": {
"type": ["integer", "null"]
},
"modified_at": {
"type": ["integer", "null"]
},
"currency_code": {
"type": ["string", "null"]
},
"tiers": {
"type": ["array", "null"],
"items": {
"type": "object",
"properties": {
"starting_unit": {
"type": ["integer", "null"]
},
"ending_unit": {
"type": ["integer", "null"]
},
"price": {
"type": ["integer", "null"]
}
}
}
},
"parent_periods": {
"type": ["array", "null"],
"items": {
"type": "object",
"properties": {
"period_unit": {
"type": ["string", "null"]
},
"period": {
"type": ["integer", "null"]
}
}
}
},
"object": {
"type": ["string", "null"]
}
}
}
1 change: 1 addition & 0 deletions docs/integrations/sources/chargebee.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ Most streams are supported regardless of your Chargebee site's [Product Catalog
| [Coupons](https://apidocs.chargebee.com/docs/api/coupons) |||
| [Credit Notes](https://apidocs.chargebee.com/docs/api/credit_notes) |||
| [Customers](https://apidocs.chargebee.com/docs/api/customers) |||
| [Differential Prices](https://apidocs.chargebee.com/docs/api/differential_prices) |||
| [Events](https://apidocs.chargebee.com/docs/api/events) |||
| [Gifts](https://apidocs.chargebee.com/docs/api/gifts) |||
| [Hosted Pages](https://apidocs.chargebee.com/docs/api/hosted_pages) |||
Expand Down

0 comments on commit 43cb3c6

Please sign in to comment.