1b.app
Link copied -

Problem with passing process to API

I'm trying to send a PUT request via the "Pass process to API" action to change the order status in Wordpress with it (the action that does this directly is not suitable because it does not trigger a chain of actions when changing the stage). It seems like nothing complicated, you just need to throw "status": "completed" at the desired link, but for some reason it doesn't work. Below I'll attach a photo of how the action is currently configured (the fields that are not in the photo are empty) and a photo of a verified working request with Python.
Original question is available on version: ru

Answers:

Install the API application in the box, there will be logs on sending a request - they will help you to understand what is wrong. If the logs on sending a request to the API are not written, look for a checkbox in the action settings so that they are written.
05.08.2024, 15:56
Original comment available on version: ru


let him cook
OneBox production wrote:
Install the API application in the box, there will be logs on sending a request - they will help you to understand what is wrong. If the logs on sending a request to the API are not written, look for a checkbox in the action settings so that they are written.

Found it, it says code 401 (not authorized). Login and password are definitely correct, but they may not be transmitted as needed, can you tell me how to configure them so that they are transmitted as a conditional parameter "auth" in Python?
05.08.2024, 16:32
Original comment available on version: ru

In the action settings there are settings with authorization types. Try different ones, most likely there is basic authorization
05.08.2024, 16:34
Original comment available on version: ru


let him cook
OneBox production wrote:
In the action settings there are settings with authorization types. Try different ones, most likely there is basic authorization

Thank you, I didn't notice this setting before, I think it will help
05.08.2024, 16:36
Original comment available on version: ru

Indeed, everything works now, thank you again
06.08.2024, 18:07
Original comment available on version: ru


Please join the conversation. If you have something to say - please write a comment. You will need a mobile phone and an SMS code for identification to enter. Log in and comment