API documentation

login img

Authorization

description Every API HTTP request should have a Header:
Authorization: Bearer $token
Approved external applications may retrieve the $token redirecting User to our OAuth2 authorization url:
https://projecteam.tools/user/oauth/login
Steps:
  1. Your app redirects user to our OAuth URL with GET:
    https://projecteam.tools/user/oauth/login?client_id=your_id&redirect_uri=your_uri
  2. User logs in our app and being redirected to your_uri&code=user_code
  3. Your app requests our OAuth URL with Header
    "Content-Type: application/x-www-form-urlencoded" and POST: client_id=your_id&client_secret=your_secret&code=user_code
  4. Our response is: {"access_token":"$token","expires_in":999999999,"token_type":"Bearer","scope":"all"}
  5. You may test user $token requesting our OAuth URL with Header
    "Authorization: Bearer $token" - we will response with {"result":"true","username":"username"}



Task View

description
"Views Task Data"
request
"GET https://projecteam.tools/project/api/task-view?id=1"
response
{
    "task": "Task Name",
    "project": "Project Name",
    "url": "http://app.projecteam.tools/project/task/1",
    "start_date": "not set",
    "end_date": "not set",
    "descr": "",
    "budget": null,
    "budget_spent": null,
    "status": "New",
    "files": "",
    "custom_fields": "",
    "clients": "",
    "guest_name": null,
    "guest_email": null,
    "guest_phone": null,
    "left_days": 0,
    "status_updated_by": null
}
param
"$id integer Task ID"



Task Create

description
"Creates A New Task"
request
"POST https://projecteam.tools/project/api/task-create"
body
{
    "project_id": "integer",
    "name": "string (required)",
    "descr": "string",
    "start_date": "string (datetime)",
    "end_date": "string (datetime)",
    "files": "string (url to a file of format: 'jpg', 'jpeg', 'gif', 'png', 'mov', 'doc', 'docx', 'pdf', 'xls', 'xlsx', 'csv', 'ppt', 'slddrw' or a zip of available formats above)",
    "assignees": "array (User IDs)"
}
response
{
    "task": "Task Name",
    "project": "Project Name",
    "url": "http://app.projecteam.tools/project/task/1",
    "start_date": "not set",
    "end_date": "not set",
    "descr": "",
    "budget": null,
    "budget_spent": null,
    "status": "New",
    "files": "",
    "custom_fields": "",
    "clients": "",
    "guest_name": null,
    "guest_email": null,
    "guest_phone": null,
    "left_days": 0,
    "status_updated_by": null
}



Task Comment Create

description
"Creates Task Comment"
param
"$id integer Task ID"
request
"POST https://projecteam.tools/project/api/task-comment-create?id=1"
body
{
    "content": "string (required)"
}
response
{
    "text": "content",
    "commenter": "User Name",
    "created_at": "08.06.2023 09:43",
    "task_name": "Task Name",
    "project_name": "Non project tasks",
    "files": "",
    "task_link": "https://app.projecteam.tools/project/task/1?key=123#comment_1",
    "project_link": "https://app.projecteam.tools/project/1"
}



Task Status

description
"Changes Task Status"
param
"$id"
"$status_id"
request
"POST https://projecteam.tools/project/api/task-status?id=1&status_id=2"
response
{
    "task": "Task Name",
    "project": "Project Name",
    "url": "http://app.projecteam.tools/project/task/1",
    "start_date": "not set",
    "end_date": "not set",
    "descr": "",
    "budget": null,
    "budget_spent": null,
    "status": "In Progress",
    "files": "",
    "custom_fields": "",
    "clients": "",
    "guest_name": null,
    "guest_email": null,
    "guest_phone": null,
    "left_days": 0,
    "status_updated_by": null
}



Task List

description
"Lists User Accessible Tasks"
request
"GET http://projecteam.tools/project/api/task-list"
response
[
    {
        "id": "1",
        "name": "Task Name 1"
    },
    {
        "id": "2",
        "name": "Task Name 2"
    }
]



Task Status List

description
"Lists Available Task Statuses"
request
"GET http://projecteam.tools/project/api/task-status-list"
response
[
    {
        "id": 1,
        "name": "New"
    },
    {
        "id": 2,
        "name": "In progress"
    },
    {
        "id": 3,
        "name": "Done"
    }
]



Project List

description
"Lists User Accessible Projects"
request
"GET http://projecteam.tools/project/api/project-list"
response
[
    {
        "id": "1",
        "name": "Project Name 1"
    },
    {
        "id": "2",
        "name": "Project Name 2"
    }
]



Task Name List

description
"Lists Default Company Task Names"
request
"GET http://projecteam.tools/project/api/task-name-list"
response
[
    {
        "id": "Default Task Name 1",
        "name": "Default Task Name 1"
    },
    {
        "id": "Default Task Name 2",
        "name": "Default Task Name 2"
    }
]



Assignee List

description
"Lists Available Task Assignees IDs"
param
"$project_id integer Project ID"
request
"GET http://projecteam.tools/project/api/assignee-list?project_id=1"
response
{
    "key": "assignees",
    "label": "Assignees",
    "choices": [
        {
            "value": 1,
            "label": "Assignee Name 1"
        },
        {
            "value": 2,
            "label": "Assignee Name 2"
        }
    ]
}