Permissions

Add a new user to a project

POST /projects/{id}/people/{id}.json

Add a user to a project. Default permissions setup in Teamwork will be used.

Response

Returns HTTP status code 200 on success. 


Add/Remove multiple people to/from a project

PUT /projects/{id}/people.json

Add or Remove multiple people to or from a project. 

Request

{
	"add" : {
		"userIdList" : "2,4,5"
	},
	"remove" : {
		"userIdList": "7,8,9"
	}
}

Response

Returns HTTP status code 200 on success. 


Remove a user from a project

DELETE /projects/{id}/people/{id}.json

Removes a user from a project.

Response

Returns HTTP status code 200 on success.


Get a users permissions on a project

GET /projects/{id}/people/{id}.json

Gets the details and permissions for a given user on a given project.

Response

{
    "people": [
        {
            "administrator": false,
            "address-city": "",
            "pid": "",
            "site-owner": false,
            "twitter": "",
            "phone-number-home": "",
            "last-name": "User",
            "email-address": "d2@demo1company.com",
            "userUUID": "",
            "user-name": "demo2",
            "company-name": "Demo 1 Company",
            "id": "999",
            "last-changed-on": "2014-04-01T14:08:07Z",
            "phone-number-office": "",
            "deleted": false,
            "address-state": "",
            "address-country": "",
            "notes": "",
            "phone-number-mobile": "",
            "first-name": "Demo 2",
            "user-type": "account",
            "permissions": {
                "add-tasks": "1",
                "view-time": "1",
                "add-messages": "1",
                "view-messages-and-files": "1",
                "view-estimated-time": "1",
                "view-tasks-and-milestones": "1",
                "add-links": "1",
                "view-notebooks": "1",
                "view-invoices": "1",
                "edit-all-tasks": "0",
                "set-privacy": "1",
                "add-milestones": "1",
                "add-time": "1",
                "is-observing": "0",
                "view-all-time-logs": "1",
                "add-taskLists": "1",
                "project-administrator": "0",
                "can-be-assigned-to-tasks-and-milestones": "1",
                "view-links": "1",
                "add-files": "1",
                "can-receive-email": "1",
                "add-notebooks": "1",
                "add-people-to-project": "0",
                "view-risk-register": "0"
            },
            "im-service": "",
            "im-handle": "",
            "address-line-2": "",
            "address-line-1": "",
            "created-at": "2014-04-01T14:08:07Z",
            "phone-number-office-ext": "",
            "company-id": "999",
            "has-access-to-new-projects": false,
            "address-zip": "",
            "phone-number-fax": "",
            "avatar-url": "http://demo1company.teamwork.com/images/demo.jpg",
            "in-owner-company": true,
            "last-login": "",
            "email-alt-1": "",
            "email-alt-2": "",
            "companyId": "2",
            "email-alt-3": "",
            "title": "Developer"
        }
    ],
    "STATUS": "OK"
}


Update a users permissions on a project

PUT /projects/{id}/people/{id}.json

Sets the permissions of a given user on a given project.

Request

{
  "permissions": {
    "view-messages-and-files": "1",
    "view-tasks-and-milestones": "1",
    "view-time": "1",
    "view-notebooks": "1",
    "view-risk-register": "0",
    "view-invoices": "1",
    "view-links": "1",
    "add-tasks": "1",
    "add-milestones": "1",
    "add-taskLists": "1",
    "add-messages": "1",
    "add-files": "1",
    "add-time": "1",
    "add-notebooks": "1",
    "add-links": "1",
    "set-privacy": "1",
    "is-observing": "1",
    "can-be-assigned-to-tasks-and-milestones": "1",
    "project-administrator": "0",
    "add-people-to-project": "0" 
  }
}

Response

Returns HTTP status code 200 on success.