QuickBuild2 Documentation
|
Access user by idSyntaxUser can be accessed by id using http GET method through below url: http://localhost:8810/rest/user?id=<user id>
The response is of mime type application/xml and the content is xml representation of the user. SecurityYou will need to use http BASIC authentication to login as authorized QuickBuild user if the anonymous does not have adminstrative rights. DemoBelow curl command demonstrates how to get user of id 1: curl -u admin:admin http://localhost:8810/rest/user?id=1
Access user by nameSyntaxUser can be accessed by name using http GET method through below url: http://localhost:8810/rest/user?name=<user name>
The response is of mime type application/xml and the content is xml representation of the user. SecurityYou will need to use http BASIC authentication to login as authorized QuickBuild user if the anonymous does not have adminstrative rights. DemoBelow curl command demonstrates how to get user of name admin: curl -u admin:admin http://localhost:8810/rest/user?name=admin
Access all users in the systemSyntaxUsers in the system can be accessed using http GET method through below url: http://localhost:8810/rest/users
The response is of mime type application/xml and the content is xml representation of list of users in the system. SecurityYou will need to use http BASIC authentication to login as authorized QuickBuild user if the anonymous does not have adminstrative rights. DemoBelow curl command demonstrates how to get all users: curl -u admin:admin http://localhost:8810/rest/users
Update userSyntaxUser can be updated by posting xml representation of the user to below url: http://localhost:8810/rest/user
Normally you do not need to create the xml from scratch: you may retrieve xml representation of the user using http GET method, modify certain parts of the xml and post back to above url.
SecurityYou will need to use http BASIC authentication to login as administrator if the anonymous does not have administrative rights. DemoWe will use curl to demonstrate how to modify password of user admin to be 12345:
Create userSyntaxUser can be created by posting xml representation of the user to below url: http://localhost:8810/rest/user
Please note that the posted xml should NOT contain the id element; otherwise, QuickBuild will treat the post as an updating to the user with that id.
SecurityYou will need to use http BASIC authentication to login as administrator if the anonymous does not have administrative rights. DemoWe will use curl to demonstrate how to create a new user robin by copying the existing user admin, and change the password to 12345.
Delete userSyntaxUser can be deleted using http DELETE method through below url: http://localhost:8810/rest/user?id=<user id>
Here <user id} stands for id of the user to be deleted. SecurityYou will need to use http BASIC authentication to login as administrator if the anonymous does not have administrative rights. DemoBelow curl command demonstrates how to delete the user with id 2: curl -X DELETE -u admin:admin http://localhost:8810/rest/user?id=2
|