Skip to content

Commit

Permalink
adds fulfillment_event and fulfillment_request (#244)
Browse files Browse the repository at this point in the history
  • Loading branch information
sx328 authored Nov 14, 2023
1 parent 6eac8e0 commit 030224d
Show file tree
Hide file tree
Showing 11 changed files with 926 additions and 2 deletions.
70 changes: 70 additions & 0 deletions fixtures/fulfillment_accept.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"fulfillment_order": {
"id": 1046000828,
"shop_id": 548380009,
"order_id": 450789469,
"assigned_location_id": 24826418,
"request_status": "accepted",
"status": "in_progress",
"supported_actions": ["request_cancellation", "create_fulfillment"],
"destination": {
"id": 1046000815,
"address1": "Chestnut Street 92",
"address2": "",
"city": "Louisville",
"company": null,
"country": "United States",
"email": "bob.norman@mail.example.com",
"first_name": "Bob",
"last_name": "Norman",
"phone": "+1(502)-459-2181",
"province": "Kentucky",
"zip": "40202"
},
"origin": {
"address1": null,
"address2": null,
"city": null,
"country_code": "DE",
"location_id": 24826418,
"name": "Apple Api Shipwire",
"phone": null,
"province": null,
"zip": null
},
"line_items": [
{
"id": 1058737564,
"shop_id": 548380009,
"fulfillment_order_id": 1046000828,
"quantity": 1,
"line_item_id": 466157049,
"inventory_item_id": 39072856,
"fulfillable_quantity": 1,
"variant_id": 39072856
},
{
"id": 1058737565,
"shop_id": 548380009,
"fulfillment_order_id": 1046000828,
"quantity": 1,
"line_item_id": 518995019,
"inventory_item_id": 49148385,
"fulfillable_quantity": 1,
"variant_id": 49148385
},
{
"id": 1058737566,
"shop_id": 548380009,
"fulfillment_order_id": 1046000828,
"quantity": 1,
"line_item_id": 703073504,
"inventory_item_id": 457924702,
"fulfillable_quantity": 1,
"variant_id": 457924702
}
],
"outgoing_requests": [],
"fulfillment_service_handle": "shipwire-app"
}
}
22 changes: 22 additions & 0 deletions fixtures/fulfillment_event.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"fulfillment_event": {
"id": 944956393,
"fulfillment_id": 255858046,
"status": "in_transit",
"message": null,
"happened_at": "2023-10-20T23:39:27-04:00",
"city": null,
"province": null,
"country": null,
"zip": null,
"address1": null,
"latitude": null,
"longitude": null,
"shop_id": 548380009,
"created_at": "2023-10-20T23:39:27-04:00",
"updated_at": "2023-10-20T23:39:27-04:00",
"estimated_delivery_at": null,
"order_id": 450789469,
"admin_graphql_api_id": "gid://shopify/FulfillmentEvent/944956393"
}
}
24 changes: 24 additions & 0 deletions fixtures/fulfillment_events.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"fulfillment_events": [
{
"id": 944956391,
"fulfillment_id": 255858046,
"status": "in_transit",
"message": null,
"happened_at": "2023-10-20T23:39:23-04:00",
"city": null,
"province": null,
"country": null,
"zip": null,
"address1": null,
"latitude": null,
"longitude": null,
"shop_id": 548380009,
"created_at": "2023-10-20T23:39:23-04:00",
"updated_at": "2023-10-20T23:39:23-04:00",
"estimated_delivery_at": null,
"order_id": 450789469,
"admin_graphql_api_id": "gid://shopify/FulfillmentEvent/944956391"
}
]
}
70 changes: 70 additions & 0 deletions fixtures/fulfillment_reject.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"fulfillment_order": {
"id": 1046000830,
"shop_id": 548380009,
"order_id": 450789469,
"assigned_location_id": 24826418,
"request_status": "rejected",
"status": "open",
"supported_actions": ["request_fulfillment", "create_fulfillment"],
"destination": {
"id": 1046000817,
"address1": "Chestnut Street 92",
"address2": "",
"city": "Louisville",
"company": null,
"country": "United States",
"email": "bob.norman@mail.example.com",
"first_name": "Bob",
"last_name": "Norman",
"phone": "+1(502)-459-2181",
"province": "Kentucky",
"zip": "40202"
},
"origin": {
"address1": null,
"address2": null,
"city": null,
"country_code": "DE",
"location_id": 24826418,
"name": "Apple Api Shipwire",
"phone": null,
"province": null,
"zip": null
},
"line_items": [
{
"id": 1058737570,
"shop_id": 548380009,
"fulfillment_order_id": 1046000830,
"quantity": 1,
"line_item_id": 466157049,
"inventory_item_id": 39072856,
"fulfillable_quantity": 1,
"variant_id": 39072856
},
{
"id": 1058737571,
"shop_id": 548380009,
"fulfillment_order_id": 1046000830,
"quantity": 1,
"line_item_id": 518995019,
"inventory_item_id": 49148385,
"fulfillable_quantity": 1,
"variant_id": 49148385
},
{
"id": 1058737572,
"shop_id": 548380009,
"fulfillment_order_id": 1046000830,
"quantity": 1,
"line_item_id": 703073504,
"inventory_item_id": 457924702,
"fulfillable_quantity": 1,
"variant_id": 457924702
}
],
"outgoing_requests": [],
"fulfillment_service_handle": "shipwire-app"
}
}
157 changes: 157 additions & 0 deletions fixtures/fulfillment_send.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
{
"original_fulfillment_order": {
"id": 1046000829,
"shop_id": 548380009,
"order_id": 450789469,
"assigned_location_id": 24826418,
"request_status": "submitted",
"status": "open",
"supported_actions": ["cancel_fulfillment_order"],
"destination": {
"id": 1046000816,
"address1": "Chestnut Street 92",
"address2": "",
"city": "Louisville",
"company": null,
"country": "United States",
"email": "bob.norman@mail.example.com",
"first_name": "Bob",
"last_name": "Norman",
"phone": "+1(502)-459-2181",
"province": "Kentucky",
"zip": "40202"
},
"origin": {
"address1": null,
"address2": null,
"city": null,
"country_code": "DE",
"location_id": 24826418,
"name": "Apple Api Shipwire",
"phone": null,
"province": null,
"zip": null
},
"line_items": [
{
"id": 1058737567,
"shop_id": 548380009,
"fulfillment_order_id": 1046000829,
"quantity": 1,
"line_item_id": 466157049,
"inventory_item_id": 39072856,
"fulfillable_quantity": 1,
"variant_id": 39072856
},
{
"id": 1058737568,
"shop_id": 548380009,
"fulfillment_order_id": 1046000829,
"quantity": 1,
"line_item_id": 518995019,
"inventory_item_id": 49148385,
"fulfillable_quantity": 1,
"variant_id": 49148385
},
{
"id": 1058737569,
"shop_id": 548380009,
"fulfillment_order_id": 1046000829,
"quantity": 1,
"line_item_id": 703073504,
"inventory_item_id": 457924702,
"fulfillable_quantity": 1,
"variant_id": 457924702
}
],
"outgoing_requests": [
{
"message": "Fulfill this ASAP please.",
"request_options": {
"notify_customer": false
},
"sent_at": "2023-10-03T13:22:49-04:00",
"kind": "fulfillment_request"
}
],
"fulfillment_service_handle": "shipwire-app"
},
"submitted_fulfillment_order": {
"id": 1046000829,
"shop_id": 548380009,
"order_id": 450789469,
"assigned_location_id": 24826418,
"request_status": "submitted",
"status": "open",
"supported_actions": ["cancel_fulfillment_order"],
"destination": {
"id": 1046000816,
"address1": "Chestnut Street 92",
"address2": "",
"city": "Louisville",
"company": null,
"country": "United States",
"email": "bob.norman@mail.example.com",
"first_name": "Bob",
"last_name": "Norman",
"phone": "+1(502)-459-2181",
"province": "Kentucky",
"zip": "40202"
},
"origin": {
"address1": null,
"address2": null,
"city": null,
"country_code": "DE",
"location_id": 24826418,
"name": "Apple Api Shipwire",
"phone": null,
"province": null,
"zip": null
},
"line_items": [
{
"id": 1058737567,
"shop_id": 548380009,
"fulfillment_order_id": 1046000829,
"quantity": 1,
"line_item_id": 466157049,
"inventory_item_id": 39072856,
"fulfillable_quantity": 1,
"variant_id": 39072856
},
{
"id": 1058737568,
"shop_id": 548380009,
"fulfillment_order_id": 1046000829,
"quantity": 1,
"line_item_id": 518995019,
"inventory_item_id": 49148385,
"fulfillable_quantity": 1,
"variant_id": 49148385
},
{
"id": 1058737569,
"shop_id": 548380009,
"fulfillment_order_id": 1046000829,
"quantity": 1,
"line_item_id": 703073504,
"inventory_item_id": 457924702,
"fulfillable_quantity": 1,
"variant_id": 457924702
}
],
"outgoing_requests": [
{
"message": "Fulfill this ASAP please.",
"request_options": {
"notify_customer": false
},
"sent_at": "2023-10-03T13:22:49-04:00",
"kind": "fulfillment_request"
}
],
"fulfillment_service_handle": "shipwire-app"
},
"unsubmitted_fulfillment_order": null
}
Loading

0 comments on commit 030224d

Please sign in to comment.