1

I need to use GET requests to retrieve the current status of a device and then update the body of a specific Wordpress post with the text data sent by the external device (for reference, it will use the following format: "YYYY-MM-DD|HH:MM:SS|VALUE1|VALUE2").

Originally I was hoping to make the device send POST requests to Wordpress through the REST API, but the device doesn't support POST requests.

Any ideas? Maybe pass the result of the GET requests as arguments for WP-CLI commands, is that at all possible?

Any thoughts are appreciated.

EDIT: added clarifying info.

  • Update a meta field? Of one certain post? Or update the body? With what exactly? Some third-party URL's status code? As in 200 or 404? – leymannx Sep 23 at 16:26
  • @leymannx, update the body of a specific post with text data sent by the external device in the following format "YYYY-MM-DD|HH:MM:SS|VALUE1|VALUE2". – Xhiko Sep 23 at 16:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.