This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.
Working with People Status in Teamwork
Overview
The following operations allow you to work with status of users. Click an operation name to see details on how to use it.
For a sample proxy service that illustrates how to work with attachments, see Sample configuration.
Operation | Description |
---|---|
createUserStatus | Create a status for a user. |
createCurrentUserStatus | Create a status for current user. |
updateUserStatus | Modifies the status of user. |
updateCurrentUserStatus | Modifies the status of current user. |
updatePeopleStatus | Modifies the status of people. |
deleteUserStatus | Delete a status of user. |
deleteCurrentUserStatus | Delete a status of current user. |
deletePeopleStatus | Delete a status of people. |
getUserStatus | Returns a single user status. |
getCurrentUserStatus | Retrieve the status of current user. |
getEverybodyStatus | Retrieves the status of everybody. |
Operation details
This section provides further details on the operations related to discussions.
Creating a user status
The createUserStatus
operation creates a new status of the user.
<teamwork.createUserStatus> <userId>{$ctx:userId}</userId> <status>{$ctx:status}</status> <notify>{$ctx:notify}</notify> </teamwork.createUserStatus>
Properties
userId
: The id of the user.status
: The new status of user.notify
: Whether notify(yes/no).
Sample Request
Following is a sample REST/JSON request that can be handled by the createUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "userId":"149195", "status": "Status message", "notify": "no" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#create_status
Creating current user status
The createCurrentUserStatus
operation creates a new status of the current user.
<teamwork.createCurrentUserStatus> <status>{$ctx:status}</status> <notify>{$ctx:notify}</notify> </teamwork.createCurrentUserStatus>
Properties
status
: The new status of user.notify
: Whether notify(yes/no).
Sample Request
Following is a sample REST/JSON request that can be handled by the createCurrentUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "status": "Status message", "notify": "no" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#create_statu
Updating a user status
The updateUserStatus
operation updates the status of the user.
<teamwork.updateUserStatus> <userId>{$ctx:userId}</userId> <statusId>{$ctx:statusId}</statusId> <status>{$ctx:status}</status> <notify>{$ctx:notify}</notify> </teamwork.updateUserStatus>
Properties
userId
: The id of the user.statusId: The id of the user status.
status
: The new status of user.notify
: Whether notify(yes/no).
Sample Request
Following is a sample REST/JSON request that can be handled by the updateUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "userId":"149195", "statusId":"29901", "status": "Status message", "notify": "no" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#update_status
Updating current user status
The updateCurrentUserStatus
operation updates the status of the current user.
<teamwork.updateCurrentUserStatus> <statusId>{$ctx:statusId}</statusId> <status>{$ctx:status}</status> <notify>{$ctx:notify}</notify> </teamwork.updateCurrentUserStatus>
Properties
statusId:
The id of the user status.status
: The new status of user.notify
: Whether notify(yes/no).
Sample Request
Following is a sample REST/JSON request that can be handled by the updateCurrentUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "statusId":"29901", "status": "Status message", "notify": "no" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#update_status
Updating the people status
The updatePeopleStatus
operation updates the status of the all users.
<teamwork.updateCurrentUserStatus> <statusId>{$ctx:statusId}</statusId> <status>{$ctx:status}</status> <notify>{$ctx:notify}</notify> </teamwork.updateCurrentUserStatus>
Properties
statusId:
The id of the user status.status
: The new status of user.notify
: Whether notify(yes/no).
Sample Request
Following is a sample REST/JSON request that can be handled by the updatePeopleStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "statusId":"29901", "status": "Status message", "notify": "no" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#update_status
Deleting a user status
The deleteUserStatus
operation deletes the status of the user.
<teamwork.deleteUserStatus> <userId>{$ctx:userId}</userId> <statusId>{$ctx:statusId}</statusId> </teamwork.deleteUserStatus>
Properties
userd:
The id of the user.statusId
: The id of the user status.
Sample Request
Following is a sample REST/JSON request that can be handled by the deleteUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "userId":"149195", "statusId": "29901" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#delete_status
Deleting the current user status
The deleteCurrentUserStatus
operation deletes the status of the current user.
<teamwork.deleteCurrentUserStatus> <statusId>{$ctx:statusId}</statusId> </teamwork.deleteCurrentUserStatus>
Properties
statusId
: The id of the user status.
Sample Request
Following is a sample REST/JSON request that can be handled by the deleteCurrentUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "statusId": "29901" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#delete_status
Deleting the people status
The deletePeopleStatus
operation deletes the status of the users.
<teamwork.deletePeopleStatus> <statusId>{$ctx:statusId}</statusId> </teamwork.deletePeopleStatus>
Properties
statusId
: The id of the user status.
Sample Request
Following is a sample REST/JSON request that can be handled by the deletePeopleStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "statusId": "29901" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#delete_status
Retrieving a user status
The getUserStatus
operation retrieves the status of a user.
<teamwork.getUserStatus> <statusId>{$ctx:statusId}</statusId> </teamwork.getUserStatus>
Properties
userId
: The id of the user.
Sample Request
Following is a sample REST/JSON request that can be handled by the getUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling", "userId": "149195" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#retrieve_a_person
Retrieving current user status
The getCurrentUserStatus
operation retrieves the status of the current user.
<teamwork.getCurrentUserStatus/>
Sample Request
Following is a sample REST/JSON request that can be handled by the getCurrentUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#retrieve_a_person
Retrieving people status
The getPeopleStatus
operation retrieves the status of the all users.
<teamwork.getEverybodyStatus/>
Sample Request
Following is a sample REST/JSON request that can be handled by the getCurrentUserStatus
operation.
{ "apiUrl":"https://wso2test.teamwork.com/", "apiKey":"clark42ceiling" }
Related Teamwork documentation
http://developer.teamwork.com/people-status#retrieve_everybod
Sample configuration
Following is a sample proxy service that illustrates how to connect to Teamwork with the init
operation and use the createUserStatus
operation. The sample request for this proxy can be found in createUserStatus sample request. You can use this sample as a template for using other operations in this category.
<?xml version="1.0" encoding="UTF-8"?> <proxy xmlns="http://ws.apache.org/ns/synapse" name="tw_createUserStatus" transports="https http" startOnLoad="true" trace="disable"> <description/> <target> <inSequence> <property name="apiUrl" expression="json-eval($.apiUrl)"/> <property name="apiKey" expression="json-eval($.apiKey)"/> <property name="userId" expression="json-eval($.userId)"/> <property name="status" expression="json-eval($.status)"/> <property name="notify" expression="json-eval($.notify)"/> <teamwork.init> <apiUrl>{$ctx:apiUrl}</apiUrl> <apiKey>{$ctx:apiKey}</apiKey> </teamwork.init> <teamwork.createUserStatus> <userId>{$ctx:userId}</userId> <status>{$ctx:status}</status> <notify>{$ctx:notify}</notify> </teamwork.createUserStatus> <respond/> </inSequence> <outSequence/> <faultSequence/> </target> </proxy>