403 error when try to create PO by api
-
Im trying to create Purchase Order by Atum API
Here rest api request (im using phpstorm for this)
POST https://***/wp-json/wc/v3/atum/purchase-orders/ Authorization: Basic ck_*** cs_*** Content-Type: application/json { "date_expected": "2022-11-11T11:26:41", "description": "Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo.", "status": "atum_ordered", "line_items": [ { "product_id": 93, "quantity": 2 }, { "product_id": 22, "variation_id": 23, "quantity": 1 } ] }But i always get a 403 error
{ "code": "woocommerce_rest_cannot_create", "message": "Lo siento, no tienes permiso para crear recursos.", "data": { "status": 403 } }Why?
GET https://***/wp-json/wc/v3/atum/purchase-orders Authorization: Basic ck_*** cs_***GET Request return – Answer – 200 [ok] but response is empty, but i have a lot of atum PO’s here (312 orders)
Where did I make a mistake and what am I doing wrong?
With the same cs_ ck_ authorization data main requests to Woocommerce like – show order list – works as expected.
Viewing 7 replies - 1 through 7 (of 7 total)
Viewing 7 replies - 1 through 7 (of 7 total)
The topic ‘403 error when try to create PO by api’ is closed to new replies.