Fulfillment 406

Three-Body
Shopify Partner
4 0 4

 

tracking_info = {
        "fulfillment": {
            "location_id": '55957913762',
            "tracking_company": "TNT",
            "tracking_number": "123456789",
            "tracking_url": "www.baidu.com",
            'order_id' : '4945712251042',
            "line_items":[
                {
                    'id': '11718958743714'
                }
            ],
            "notify_customer": False
        }
    }

shopify.Fulfillment.create(tracking_info)

I execute the following code to create fulfillment

report errors: 406: Not Acceptable

'X-Request-ID': '3d448b6c-5b9e-4878-9587-9c06cfa5ca14'

 

I am a novice. This question has bothered me for a long time. I hope it can be answered

 

 

 

Reply 1 (1)

ski_power
Shopify Partner
9 2 1

Can you try enclosing your object in ``. That is,

 

tracking_info = `{ "fulfillment": { "location_id": '55957913762', "tracking_company": "TNT", "tracking_number": "123456789", "tracking_url": "www.baidu.com", 'order_id' : '4945712251042', "line_items":[ { 'id': '11718958743714' } ], "notify_customer": False } }`;

shopify.Fulfillment.create(tracking_info)