Custom Endpoint : how to get data in body from POST method
-
Hi WordPress REST API’s team
I have read Plugin Document carefully but couldn’t find any example of how to retrieve data in body from
POST
request. What was written in the document is to show how to create custom endpoint forGET
method. Now I can only read variables attached to URL like this
register_rest_route( 'myplugin/v1', '/something/(?P<somedata>\S+)', array(...) );
But still have no idea how to read body data in POST Request.
Thanks in advance.
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Custom Endpoint : how to get data in body from POST method’ is closed to new replies.