Is there a way I can return the username and password of a particular user using the Wordpress API?
Wordpress seems to have the password field as WRITE-ONLY in their API documentation.
I can pull the user's details in POSTMAN by doing a simple API call here:
https://example.com/wp-json/wc/v3/customers?consumer_key=xxxx&consumer_secret=xxxx&email=xxxx
And here's the result:
[
{
"id": 29288,
"date_created": "2020-07-09T22:48:47",
"date_created_gmt": "2020-07-09T12:48:47",
"date_modified": "2020-08-12T23:19:16",
"date_modified_gmt": "2020-08-12T13:19:16",
"email": "xxxxu",
"first_name": "xxxx",
"last_name": "xxxx",
"role": "customer",
"username": "xxxx",
"billing": {
"first_name": "xxx",
"last_name": "xxxx",
But I can't see the user's password.
The reason why I want to see the user's password so that my app can validate the username and password that was entered in the login screen against the returned json response before proceeding to the next page.
If this is due to security policies, any recommendations on how you could validate username / password against Wordpress API?
Any advice would be helpful.
solved the problem. Need to use JWT Auth plugin and you can get authenticate the username and password.