php-shopify icon indicating copy to clipboard operation
php-shopify copied to clipboard

Fullfillments for 2022-07 version

Open damix1984 opened this issue 3 years ago • 8 comments

in version 2022-07 the orders/$id/fulfillments.json API is no more present.

We need to use the $client->Fulfillments making Fulfillment not a Child resource for orders but a Resource itself, to be able to call fulfillments.json endpoint.

This is related to https://github.com/phpclassic/php-shopify/issues/264

damix1984 avatar Oct 06 '22 08:10 damix1984

Hi, I have the same issue in my projects. I need to use API 2022-07 to manage Shopify Markets and now the fulfillment of order stop to work. Thanks for the support.

lpiccini21 avatar Oct 06 '22 12:10 lpiccini21

Hi there, how come the fullfillment api are gone with out a backward compatibility? they are precious to me too.. Please put them back in version 2022-07 and in the following versions.

Best. Francesco.

fzoccara avatar Oct 06 '22 12:10 fzoccara

Multiple endpoints from the Fulfillment resource have been removed as of the 2022-07 API version. Use the FulfillmentOrder resource instead. For more information about migrating to FulfillmentOrder, refer to the Fulfillment orders migration guide.

@lpiccini21 you should migrate to FulfillmentOrder instead of Order

Hi there, how come the fullfillment api are gone with out a backward compatibility? they are precious to me too.. Please put them back in version 2022-07 and in the following versions.

Best. Francesco.

@fzoccara Shopify totally removed it in version 2022-07, if you still want to use that API, you can use a self-defined API Version in the $config array and switch back to older version. Like this

$config = array(
    'ShopUrl' => 'yourshop.myshopify.com',
    'AccessToken' => '***ACCESS-TOKEN-FOR-THIRD-PARTY-APP***',
    'ApiVersion' => '2022-04',
);

nVuln avatar Oct 06 '22 15:10 nVuln

@nVuln Fulfillment resources are still available, they are not removed. Only the Order/Fulfillment resources are no more available:

https://shopify.dev/api/admin-rest/2022-10/resources/fulfillment

POST /admin/api/2022-10/fulfillments.json POST /admin/api/2022-10/fulfillments/1069019871/update_tracking.json

and so on...

damix1984 avatar Oct 06 '22 15:10 damix1984

@damix1984 yup, I mean they removed order->fulfillment api, but if you still want to use it, just re-defined api version to 2022-07, this is temporarily until you totally migrate your code to their new api version

nVuln avatar Oct 07 '22 08:10 nVuln

I've done some work towards this goal, although I'm not sure this covers all scenarios.

https://github.com/phpclassic/php-shopify/pull/278

jeroendelau avatar Nov 17 '22 16:11 jeroendelau

@damix1984 : Strangely, i got the below response from Shopify

Another solution that you could consider is to use the REST Admin API, which provides more granular control over the fulfillment process. You can use the POST /admin/api/2022-01/orders/#{id}/fulfillments.json endpoint to update the fulfillment

Does that mean admin/api/2021-01/orders/$id/fulfillments.json is not the one that is getting deprecated?

tonytoms avatar Dec 19 '22 02:12 tonytoms

@damix1984 : Strangely, i got the below response from Shopify

Another solution that you could consider is to use the REST Admin API, which provides more granular control over the fulfillment process. You can use the POST /admin/api/2022-01/orders/#{id}/fulfillments.json endpoint to update the fulfillment

Does that mean admin/api/2021-01/orders/$id/fulfillments.json is not the one that is getting deprecated?

@tonytoms It is deprecated and removed since 2022-07 version, so it still works in 2022-01, but no more since 2022-07

damix1984 avatar Dec 19 '22 14:12 damix1984