Closed as not planned
Closed as not planned
Description
Issue summary
When calling shopify.Fulfillment.create the resulting URL is incorrect preventing the successful creation of the Fulfillment record.
Expected behavior
The URL generated by the Shopify client library should be
/admin/api/<API_VERSION>/fulfillments.json
Actual behavior
The URL generated by the Shopify client library is
/admin/api/<API_VERSION>/orders//fulfillments.json
NOTE: The call to shopify.Fulfillment.create does not accept an order_id parameter.
Steps to reproduce the problem
- Create Shopify session with api_version set to '2023-01'
- Call shopify.Fulfillment.create with a valid fulfillment payload
Reduced test case
import logging
import shopify
logging.basicConfig(level=logging.DEBUG)
shop_uri = 'xxx.myshopify.com'
api_version = '2023-01'
access_token = 'shppa_xxx'
session = shopify.Session(shop_uri, api_version, access_token)
shopify.ShopifyResource.activate_session(session)
payload = dict(
line_items_by_fulfillment_order=[dict(fulfillment_order_id="5894084460693", fulfillment_order_line_items=[
dict(id="12190922277013", quantity="1")])])
shopify.Fulfillment.create(payload)
The best way to get your bug fixed is to provide a reduced test case.
Checklist
- I have described this issue in a way that is actionable (if possible)