Update Profile¶
Updates the profile’s info.
Resource Information¶
This service uses the tomcat application on port 8080 by default. To see a list of default ports click here
The context for this API is /crafter-profile
, please prefix the API URLs with this context.
HTTP Verb
|
POST
|
URL
|
/api/1/profile/:id/update |
Response Formats
|
JSON |
Parameters¶
Name
|
Type
|
Required
|
Description
|
---|---|---|---|
accessTokenId
|
String
|
✓
|
The access token ID of the application
making the call
|
id
|
String
|
✓
|
The profile’s ID
|
username
|
String
|
✓
|
The new username for the profile
|
password
|
String
|
The new password for the profile
|
|
email
|
String
|
✓
|
The new email for the profile
|
enabled
|
String
|
✓
|
If the profile should be enabled or not
|
role
|
String
|
The new roles for the profile
|
|
attributes
|
String
|
The attributes to update (specify a JSON string)
|
|
attributesToReturn
|
String
|
The name of the attributes to return
(don’t specify to return all)
|
Example¶
Request¶
POST .../api/1/profile/592887d7d4c650213cc2f400/update
accessTokenId=e8f5170c-877b-416f-b70f-4b09772f8e2d
username=john.doe
password=passw0rd
email=john.doe@example.com
enabled=false
role=APP_TEST,APP_REPORT
Response¶
Status 200 OK
1{
2 "username": "john.doe",
3 "email": "john.doe@example.com",
4 "verified": false,
5 "enabled": false,
6 "createdOn": 1495828439317,
7 "lastModified": 1495828570508,
8 "tenant": "sample-tenant",
9 "roles": [
10 "APP_TEST",
11 "APP_REPORT"
12 ],
13 "attributes": {
14 "firstName": "John",
15 "lastName": "Doe"
16 },
17 "id": "592887d7d4c650213cc2f400"
18}
Responses¶
Status
|
Location
|
Response Body
|
---|---|---|
200
|
See example above.
|
|
500
|
{ "message" : "Internal server error" } |