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

Amazon Seller Partner: new stream orderitems #29210

Merged
merged 14 commits into from
Aug 8, 2023
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ ENV AIRBYTE_ENTRYPOINT "python /airbyte/integration_code/main.py"
ENTRYPOINT ["python", "/airbyte/integration_code/main.py"]


LABEL io.airbyte.version=1.4.1
LABEL io.airbyte.version=1.5.0
LABEL io.airbyte.name=airbyte/source-amazon-seller-partner
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ acceptance_tests:
bypass_reason: "no records"
incremental:
tests:
- config_path: "secrets/config_old_data.json"
- config_path: "secrets/config.json"
configured_catalog_path: "integration_tests/configured_catalog_incremental.json"
timeout_seconds: 3600
future_state:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
{
"streams": [
{
"stream": {
"name": "OrderItems",
"json_schema": {},
"supported_sync_modes": ["full_refresh", "incremental"],
"source_defined_cursor": true,
"default_cursor_field": ["LastUpdateDate"]
},
"sync_mode": "incremental",
"destination_sync_mode": "append",
"cursor_field": ["LastUpdateDate"]
},
{
"stream": {
"name": "Orders",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@
{"stream": "GET_MERCHANT_LISTINGS_INACTIVE_DATA", "data": {"item-name": "GiftBox", "item-description": "", "listing-id": "0711ZJWAW1J", "seller-sku": "G3-8N7Y-L93I", "price": "6", "quantity": "1000", "open-date": "2022-07-11 01:48:47 PDT", "image-url": "", "item-is-marketplace": "y", "product-id-type": "1", "zshop-shipping-fee": "", "item-note": "", "item-condition": "11", "zshop-category1": "", "zshop-browse-path": "", "zshop-storefront-feature": "", "asin1": "B0B68NBQ1Y", "asin2": "", "asin3": "", "will-ship-internationally": "", "expedited-shipping": "", "zshop-boldface": "", "product-id": "B0B68NBQ1Y", "bid-for-featured-placement": "", "add-delete": "", "pending-quantity": "0", "fulfillment-channel": "DEFAULT", "merchant-shipping-group": "Migrated Template"}, "emitted_at": 1690223127429}
{"stream": "GET_MERCHANT_LISTINGS_INACTIVE_DATA", "data": {"item-name": "Beyond Meat, Plant-Based Patties, Vegan, 8 Oz, 2 Patties", "item-description": "", "listing-id": "0711ZJW1CW7", "seller-sku": "M6-KYAA-V7O7", "price": "10", "quantity": "999999", "open-date": "2022-07-11 01:16:54 PDT", "image-url": "", "item-is-marketplace": "y", "product-id-type": "1", "zshop-shipping-fee": "", "item-note": "", "item-condition": "11", "zshop-category1": "", "zshop-browse-path": "", "zshop-storefront-feature": "", "asin1": "B074K5MDLW", "asin2": "", "asin3": "", "will-ship-internationally": "", "expedited-shipping": "", "zshop-boldface": "", "product-id": "B074K5MDLW", "bid-for-featured-placement": "", "add-delete": "", "pending-quantity": "0", "fulfillment-channel": "DEFAULT", "merchant-shipping-group": "Migrated Template"}, "emitted_at": 1690223127429}
{"stream": "GET_MERCHANT_LISTINGS_INACTIVE_DATA", "data": {"item-name": "House Foods, Organic Firm Tofu, 14 oz", "item-description": "", "listing-id": "0705Z8HWWAY", "seller-sku": "MP-V4RG-EDEY", "price": "5", "quantity": "1518", "open-date": "2022-07-05 08:00:10 PDT", "image-url": "", "item-is-marketplace": "y", "product-id-type": "1", "zshop-shipping-fee": "", "item-note": "", "item-condition": "1", "zshop-category1": "", "zshop-browse-path": "", "zshop-storefront-feature": "", "asin1": "B000VHRNUW", "asin2": "", "asin3": "", "will-ship-internationally": "", "expedited-shipping": "", "zshop-boldface": "", "product-id": "B000VHRNUW", "bid-for-featured-placement": "", "add-delete": "", "pending-quantity": "0", "fulfillment-channel": "DEFAULT", "merchant-shipping-group": "Migrated Template"}, "emitted_at": 1690223127429}
{"stream": "Orders", "data": {"BuyerInfo": {}, "AmazonOrderId": "112-4052057-4266618", "EarliestShipDate": "2022-07-25T07:00:00Z", "SalesChannel": "Amazon.com", "AutomatedShippingSettings": {"HasAutomatedShippingSettings": false}, "OrderStatus": "Canceled", "NumberOfItemsShipped": 0, "OrderType": "StandardOrder", "IsPremiumOrder": false, "IsPrime": false, "FulfillmentChannel": "MFN", "NumberOfItemsUnshipped": 0, "HasRegulatedItems": false, "IsReplacementOrder": "false", "IsSoldByAB": false, "LatestShipDate": "2022-07-26T06:59:59Z", "ShipServiceLevel": "Std US D2D Dom", "IsISPU": false, "MarketplaceId": "ATVPDKIKX0DER", "PurchaseDate": "2022-07-22T20:25:05Z", "IsAccessPointOrder": false, "IsBusinessOrder": false, "OrderTotal": {"CurrencyCode": "USD", "Amount": "7.00"}, "PaymentMethodDetails": ["Standard"], "IsGlobalExpressEnabled": false, "LastUpdateDate": "2022-09-01T13:16:42Z", "ShipmentServiceLevelCategory": "Standard"}, "emitted_at": 1691499338977}
{"stream": "OrderItems", "data": {"ProductInfo": {"NumberOfItems": "1"}, "BuyerInfo": {}, "ItemTax": {"CurrencyCode": "USD", "Amount": "0.00"}, "QuantityShipped": 0, "BuyerRequestedCancel": {"IsBuyerRequestedCancel": "false", "BuyerCancelReason": ""}, "ItemPrice": {"CurrencyCode": "USD", "Amount": "7.00"}, "ASIN": "B074K5MDLW", "SellerSKU": "2J-D6V7-C8XI", "Title": "Beyond Meat Beyond Burger Plant-Based Patties 2 pk, 8 oz (Frozen)", "IsGift": "false", "ConditionSubtypeId": "New", "IsTransparency": false, "QuantityOrdered": 0, "PromotionDiscountTax": {"CurrencyCode": "USD", "Amount": "0.00"}, "ConditionId": "New", "PromotionDiscount": {"CurrencyCode": "USD", "Amount": "0.00"}, "OrderItemId": "00860509139506", "LastUpdateDate": "2022-09-01T13:16:42Z", "AmazonOrderId": "112-4052057-4266618"}, "emitted_at": 1691499343416}
Original file line number Diff line number Diff line change
@@ -1,13 +1,24 @@
[
{
"type": "STREAM",
"stream": {
"stream_state": {
"LastUpdateDate": "2121-07-01T00:00:00Z"
},
"stream_descriptor": {
"name": "Orders"
}
}
}
]
{
"type": "STREAM",
"stream": {
"stream_state": {
"LastUpdateDate": "2121-07-01T00:00:00Z"
},
"stream_descriptor": {
"name": "OrderItems"
}
}
},
{
"type": "STREAM",
"stream": {
"stream_state": {
"LastUpdateDate": "2121-07-01T00:00:00Z"
},
"stream_descriptor": {
"name": "Orders"
}
}
}
]
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ data:
connectorSubtype: api
connectorType: source
definitionId: e55879a8-0ef8-4557-abcf-ab34c53ec460
dockerImageTag: 1.4.1
dockerImageTag: 1.5.0
dockerRepository: airbyte/source-amazon-seller-partner
githubIssueLabel: source-amazon-seller-partner
icon: amazonsellerpartner.svg
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,290 @@
{
"title": "Order Items",
"description": "All order items that were updated after a specified date",
"$schema": "http://json-schema.org/draft-07/schema#",
"type": "object",
"additionalProperties": true,
"properties": {
"AmazonOrderId": {
"type": ["null", "string"]
},
"ASIN": {
"type": ["null", "string"]
},
"OrderItemId": {
"type": ["null", "string"]
},
"SellerSKU": {
"type": ["null", "string"]
},
"Title": {
"type": ["null", "string"]
},
"QuantityOrdered": {
"type": ["null", "integer"]
},
"ProductInfo": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"NumberOfItems": {
"type": ["null", "string"]
}
}
},
"QuantityShipped": {
"type": ["null", "integer"]
},
"PointsGranted": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"PointsNumber": {
"type": ["null", "integer"]
},
"PointsMonetaryValue": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
}
}
},
"ItemPrice": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"PromotionIds": {
"type": ["null", "array"],
"items": {
"type": ["null", "string"]
}
},
"ItemTax": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"ShippingPrice": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"ShippingTax": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"ShippingDiscount": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"ShippingDiscountTax": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"PromotionDiscount": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"PromotionDiscountTax": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"ScheduledDeliveryEndDate": {
"type": ["null", "string"],
"format": "date-time"
},
"ScheduledDeliveryStartDate": {
"type": ["null", "string"],
"format": "date-time"
},
"CODFee": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"IsGift": {
"type": ["null", "string"]
},
"ConditionNote": {
"type": ["null", "string"]
},
"ConditionId": {
"type": ["null", "string"]
},
"ConditionSubtypeId": {
"type": ["null", "string"]
},
"CODFeeDiscount": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"TaxCollection": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"Model": {
"type": ["null", "string"]
},
"ResponsibleParty": {
"type": ["null", "string"]
}
}
},
"IsTransparency": {
"type": ["null", "boolean"]
},
"IossNumber": {
"type": ["null", "string"]
},
"SerialNumberRequired": {
"type": ["null", "boolean"]
},
"StoreChainStoreId": {
"type": ["null", "string"]
},
"DeemedResellerCategory": {
"type": ["null", "string"]
},
"PriceDesignation": {
"type": ["null", "string"]
},
"BuyerInfo": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"BuyerCustomizedInfo": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CustomizedURL": {
"type": ["null", "string"]
}
}
},
"GiftMessageText": {
"type": ["null", "string"]
},
"GiftWrapPrice": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"CurrencyCode": {
"type": ["null", "string"]
},
"Amount": {
"type": ["null", "string"]
}
}
},
"GiftWrapLevel": {
"type": ["null", "string"]
}
}
},
"BuyerRequestedCancel": {
"type": ["null", "object"],
"additionalProperties": true,
"properties": {
"IsBuyerRequestedCancel": {
"type": ["null", "string"]
},
"BuyerCancelReason": {
"type": ["null", "string"]
}
}
},
"SerialNumbers": {
"type": ["null", "array"],
"items": {
"type": ["null", "string"]
}
},
"LastUpdateDate": {
"type": ["null", "string"]
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
MerchantListingsReport,
MerchantListingsReportBackCompat,
MerchantListingsReports,
OrderItems,
OrderReportDataShipping,
Orders,
RestockInventoryReports,
Expand Down Expand Up @@ -179,6 +180,7 @@ def streams(self, config: Mapping[str, Any]) -> List[Stream]:
VendorInventoryReports(**stream_kwargs),
VendorSalesReports(**stream_kwargs),
Orders(**stream_kwargs),
OrderItems(**stream_kwargs),
OrderReportDataShipping(**stream_kwargs),
SellerAnalyticsSalesAndTrafficReports(**stream_kwargs),
SellerFeedbackReports(**stream_kwargs),
Expand Down
Loading