...
Note: As a side effect this will send an email to the given address, prompting the user to set their password.
Get User
...
Send Change-Password Email
Code Block |
---|
GETPOST https://auth-staging.sagebase.org/auth/v1/user userPasswordEmail {"email":"demouser@sagebase.org"} |
Successful Response:
Code Block |
---|
HTTP/1.1 200204 OKNo Content-Type: application/json { "displayName": "Demo User", "email": "demouser@sagebase.org", "firstName": "demo", "lastName": "user", "password": null } |
Update User
Code Block |
---|
PUT https://auth-staging.sagebase.org/auth/v1/user
sessionToken:<sessionToken>
{"firstName":"demo", "lastName":"user", "displayName":"Demo User"}
|
where <sessionToken> is that returned by "Initiate Session", below. This service updates the user who is authenticated by the session token.
Note the authentication service manage the properties shown (principally the userId and password) while the repository services (below) manage other related user attributes.
Successful Response:
Code Block |
---|
HTTP/1.1 204 No Content
|
Error Response, if the session token is missing or does not match userId:
Code Block |
---|
HTTP/1.1 400 Bad Request
Content-Type: application/json
{"reason":"Not authorized."}
|
Send Change-Password Email
Code Block |
---|
POST https://auth-staging.sagebase.org/auth/v1/userPasswordEmail
{"email":"demouser@sagebase.org"}
|
Successful Response:
Code Block |
---|
HTTP/1.1 204 No Content
|
...
|
If the email address is not in the user database:
...
Code Block |
---|
GET https://repo-staging.sagebase.org/repo/v1/user?offset=1&limit=100
|
Code Block |
---|
[ {"nametotalNumberOfResults":"anonymous@sagebase.org","id":"3","creationDate":1307402971000,"uri":null,"etag":null,"individual":true}, {"name":"foo@sagebase.org","id":"4","creationDate":1307403226000,"uri":null,"etag":null,"individual":true} ]340, "results":[ {"lastName":"Bar","etag":"403","ownerId":"273956","firstName":"Foo","displayName":"Foo Bar"}, .... ], "paging":{"next":"/repo/v1/user?offset=101&limit=100"} } |
Get the groups who can be added to a resource's ACL
...