Hey @RobZone ,
I’ve tried with both the same API client as the fulfillment service app and I’ve tried with a different client, to see if that was somehow the cause.
Here is an example request:
PUT https://*********.myshopify.com/admin/api/2023-01/variants/44140965855396.json HTTP/1.1
X-Shopify-Access-Token: *********
Content-Type: application/json
User-Agent: PostmanRuntime/7.31.1
Accept: */*
Cache-Control: no-cache
Host: *********.myshopify.com
Accept-Encoding: gzip, deflate, br
Connection: keep-alive
Content-Length: 88
{
"variant":
{
"inventory_management":"shopify"
}
}
Here is the response received:
HTTP/1.1 200 OK
Date: Fri, 24 Feb 2023 00:52:48 GMT
Content-Type: application/json; charset=utf-8
Connection: keep-alive
Vary: Accept-Encoding
Referrer-Policy: origin-when-cross-origin
Location: https://********.myshopify.com/admin/products/8104291795108/variants/44140965855396
Server: cloudflare
Content-Length: 753
{"variant":{"id":44140965855396,"product_id":8104291795108,"title":"Apple Green \/ XS","price":"10.00","sku":"SAMPLE_SKU","position":2,"inventory_policy":"deny","compare_at_price":null,"fulfillment_service":"manual","inventory_management":null,"option1":"Apple Green","option2":"XS","option3":null,"created_at":"2023-01-18T12:21:20-05:00","updated_at":"2023-02-15T09:54:33-05:00","taxable":true,"barcode":null,"grams":0,"image_id":42338861187236,"weight":0.0,"weight_unit":"lb","inventory_item_id":45988815306916,"inventory_quantity":0,"old_inventory_quantity":0,"requires_shipping":true,"admin_graphql_api_id":"gid:\/\/shopify\/ProductVariant\/44140965855396"}}
Calling the GET Variant endpoint also shows “inventory_management”:null. If I click the “Track quantity” checkbox in the UI, then the value of inventory_management becomes shopify on the GET endpoint, and I have the reverse issue where trying to set it to null through the PUT no longer works.
Lastly, if I disconnect the variant from my fulfillment service app location, then I am able to toggle this value through the API call above.