- πΊπΈUnited States grasmash
For resetting password, POST a request to /jsonapi/user/password/reset with either a mail or name property in the body.
- πΊπΈUnited States grasmash
For user registration:
curl --location 'https://www.example.com/jsonapi/user/register' \ --header 'Content-Type: application/vnd.api+json' \ --header 'Accept: application/vnd.api+json' \ --data-raw '{ "data": { "type": "user--user", "attributes": { "name": "test 123", "mail": "test@test123456.com", "pass": "test" } } }'
- πΊπΈUnited States grasmash
And, if you want to change the email address or password for the user, you need to make a request like this. Current password is required for changing either mail or password.
curl --location --request PATCH 'https://www.example.com/jsonapi/user/user/1876ac28-5163-4ada-9ab7-481f60e6ed34' \ --header 'Content-Type: application/vnd.api+json' \ --header 'Accept: application/vnd.api+json' \ --header 'Authorization: Bearer [token]' \ --data-raw '{ "data": { "type": "user--user", "id": "1876ac28-5163-4ada-9ab7-481f60e6ed34", "attributes": { "name": "test 1234", "mail": "test@example.com", "pass": { "existing": "test", "value": "test1" } } } }'