4. π Example: Updating Member Information (PUT Request)
Description:
In this example, you will update a memberβs information, such as their email or password.
Steps:
- In Postman, set the request method to PUT.
- Enter the URL:
https://your-site.com/wp-json/mp/v1/members/{member_id}Replace{member_id}with the ID of the member you want to update (e.g.,3). - In the Authorization tab, select Bearer Token and add your API Key.
- Go to the Body tab and select raw with the format set to JSON.
- Enter the new information for the member, for example:
{ "email": "newemail@example.com" } - Click Send.
Expected Response:
A confirmation showing the updated details:
{
"id": 3,
"username": "newmember",
"email": "newemail@example.com",
"status": "active"
}