{"id":13093,"date":"2020-10-30T11:42:16","date_gmt":"2020-10-30T10:42:16","guid":{"rendered":"https:\/\/wpstaging.timetrackapp.com\/api\/api-tasks\/"},"modified":"2023-03-01T12:36:11","modified_gmt":"2023-03-01T11:36:11","slug":"tasks","status":"publish","type":"page","link":"https:\/\/wpstaging.timetrackapp.com\/en\/api\/tasks\/","title":{"rendered":"API &#8211; Tasks"},"content":{"rendered":"\n<style type=\"text\/css\" data-created_by=\"avia_inline_auto\" id=\"style-css-av-k6jj58ve-4d1f16dc3a5c8647855d83f7f4eaf395\">\n.avia-section.av-k6jj58ve-4d1f16dc3a5c8647855d83f7f4eaf395{\nbackground-repeat:no-repeat;\nbackground-image:url(https:\/\/wpstaging.timetrackapp.com\/wp-content\/uploads\/2020\/02\/img_are_you_freelancer.jpg);\nbackground-position:50% 50%;\nbackground-attachment:scroll;\n}\n.avia-section.av-k6jj58ve-4d1f16dc3a5c8647855d83f7f4eaf395 .av-section-color-overlay{\nopacity:1;\n}\n<\/style>\n<div id='call-to-action'  class='avia-section av-k6jj58ve-4d1f16dc3a5c8647855d83f7f4eaf395 main_color avia-section-large avia-no-border-styling  avia-builder-el-0  el_before_av_three_fourth  avia-builder-el-first  avia-bg-style-scroll av-section-color-overlay-active container_wrap fullsize'  data-section-bg-repeat='no-repeat'><div class=\"av-section-color-overlay-wrap\"><div class=\"av-section-color-overlay\"><\/div><div class='container av-section-cont-open' ><main  role=\"main\" itemprop=\"mainContentOfPage\"  class='template-page content  av-content-full alpha units'><div class='post-entry post-entry-type-page post-entry-13093'><div class='entry-content-wrapper clearfix'>\n<section  class='av_textblock_section av-k6jjc1w6-d2a3e2b3ffad0185ecf50fe4378d1a8d '   itemscope=\"itemscope\" itemtype=\"https:\/\/schema.org\/CreativeWork\" ><div class='avia_textblock'  itemprop=\"text\" ><h1 class=\"custom_h1\" style=\"color: #fff;\">API<\/h1>\n<p><span style=\"color: #ffffff;\">Use TimeTrack Rest API to integrate TimeTrack with other systems.<br \/>\nHappy Coding!<\/span><\/p>\n<\/div><\/section>\n<\/div><\/div><\/main><!-- close content main element --><\/div><\/div><\/div><div id='after_section_1'  class='main_color av_default_container_wrap container_wrap fullsize'  ><div class='container av-section-cont-open' ><div class='template-page content  av-content-full alpha units'><div class='post-entry post-entry-type-page post-entry-13093'><div class='entry-content-wrapper clearfix'>\n<style type=\"text\/css\" data-created_by=\"avia_inline_auto\" id=\"style-css-av-o96lra-d682cd4dcb7c0921594375424522d6c8\">\n.flex_column.av-o96lra-d682cd4dcb7c0921594375424522d6c8{\nborder-radius:0px 0px 0px 0px;\npadding:0px 0px 0px 0px;\n}\n<\/style>\n<div  class='flex_column av-o96lra-d682cd4dcb7c0921594375424522d6c8 av_three_fourth  avia-builder-el-2  el_after_av_section  el_before_av_one_fifth  avia-builder-el-first  first flex_column_div av-zero-column-padding  '     ><section  class='av_textblock_section av-5dzxbao-ff2e6b2f2f3b105aee569e8ac6cf19bf '   itemscope=\"itemscope\" itemtype=\"https:\/\/schema.org\/CreativeWork\" ><div class='avia_textblock page_api'  itemprop=\"text\" ><h2>Tasks<\/h2>\n<p>With tasks endpoint you can:<\/p>\n<ul>\n<li>Get all tasks without filter<\/li>\n<li>Get all tasks with filter<\/li>\n<li>Read task<\/li>\n<li>Create task<\/li>\n<li>Update task<\/li>\n<li>Delete task<\/li>\n<\/ul>\n<p>Task object has following params:<\/p>\n<table>\n<tbody>\n<tr>\n<th>Param<\/th>\n<th>Type<\/th>\n<th>Description<\/th>\n<\/tr>\n<tr>\n<td>ID<\/td>\n<td>Integer<\/td>\n<td>ID<\/td>\n<\/tr>\n<tr>\n<td>name<\/td>\n<td>Text<\/td>\n<td>Task name<\/td>\n<\/tr>\n<tr>\n<td>notes<\/td>\n<td>Text<\/td>\n<td>Notes<\/td>\n<\/tr>\n<tr>\n<td>hourRate<\/td>\n<td>Number<\/td>\n<td>Houry rate<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Get all tasks without filter<\/h3>\n<blockquote>\n<p>curl &#8220;https:\/\/testaccount.timetrackenterprise.com\/api\/v2\/ext\/tasks\/&#8221;<br \/>\n-H &#8216;Content-Type: application\/json&#8217;<br \/>\n-H &#8216;X-TimeTrack-Api-Secret: &lt;<em>API_SECRET_TOKEN&gt;<\/em>&#8216;<br \/>\n-H &#8216;X-TimeTrack-Api-Key: &lt;<em>API_KEY&gt;<\/em>&#8216;<br \/>\n-d $'{}&#8217;<\/p>\n<\/blockquote>\n<h3>Get all tasks with search \/ filter<\/h3>\n<p>You can use following params:<\/p>\n<table>\n<tbody>\n<tr>\n<th>Param<\/th>\n<th>Type<\/th>\n<th>Description<\/th>\n<\/tr>\n<tr>\n<td>name<\/td>\n<td>Text<\/td>\n<td>Task name, will be used as substring.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>In this example we search for tasks that contain\u00a0<em>test<\/em> in task name.<\/p>\n<blockquote>\n<p>curl &#8220;https:\/\/testkonto.timetrackenterprise.com\/api\/v2\/ext\/tasks?name=est&#8221;<br \/>\n-H &#8216;Content-Type: application\/json&#8217;<br \/>\n-H &#8216;X-TimeTrack-Api-Secret: &lt;<em>API_SECRET_TOKEN&gt;<\/em>&#8216;<br \/>\n-H &#8216;X-TimeTrack-Api-Key: &lt;<em>API_KEY&gt;<\/em>&#8216;<br \/>\n-d $'{}&#8217;<\/p>\n<\/blockquote>\n<h3>Read task<\/h3>\n<p><strong>Required params<\/strong>: ID.<\/p>\n<blockquote>\n<p>curl &#8220;https:\/\/testkonto.timetrackenterprise.com\/api\/v2\/ext\/tasks\/1&#8221;<br \/>\n-H &#8216;Content-Type: application\/json&#8217;<br \/>\n-H &#8216;X-TimeTrack-Api-Secret: &lt;<em>API_SECRET_TOKEN&gt;<\/em>&#8216;<br \/>\n-H &#8216;X-TimeTrack-Api-Key: &lt;<em>API_KEY&gt;<\/em>&#8216;<br \/>\n-d $'{}&#8217;<\/p>\n<\/blockquote>\n<h3>Create task<\/h3>\n<p>For create method you can use all params of task object.<\/p>\n<p><strong>Required params<\/strong>: name<\/p>\n<blockquote>\n<p>curl -X &#8220;POST&#8221;\u00a0&#8220;https:\/\/testaccount.timetrackenterprise.com\/api\/v2\/ext\/tasks&#8221;<br \/>\n-H &#8216;Content-Type: application\/json&#8217;<br \/>\n-H &#8216;X-TimeTrack-Api-Secret: &lt;<em>API_SECRET_TOKEN&gt;<\/em>&#8216;<br \/>\n-H &#8216;X-TimeTrack-Api-Key: &lt;<em>API_KEY&gt;<\/em>&#8216;<br \/>\n-d $'{<br \/>\n&#8220;name&#8221;: &#8220;Development&#8221;,<br \/>\n&#8220;hourRate&#8221;: 30.0<br \/>\n}&#8217;<\/p>\n<\/blockquote>\n<h3>Update task<\/h3>\n<p>For update method you can use all params of task object except: name.<\/p>\n<blockquote>\n<p>curl -X &#8220;PUT&#8221;\u00a0&#8220;https:\/\/testaccount.timetrackenterprise.com\/api\/v2\/ext\/tasks\/1&#8221;<br \/>\n-H &#8216;Content-Type: application\/json&#8217;<br \/>\n-H &#8216;X-TimeTrack-Api-Secret: &lt;<em>API_SECRET_TOKEN&gt;<\/em>&#8216;<br \/>\n-H &#8216;X-TimeTrack-Api-Key: &lt;<em>API_KEY&gt;<\/em>&#8216;<br \/>\n-d $'{<br \/>\n&#8220;hourRate&#8221;: 35.5,<br \/>\n&#8220;notes&#8221;: &#8220;Test task for API&#8221;<br \/>\n}&#8217;<\/p>\n<\/blockquote>\n<h3>Delete task<\/h3>\n<blockquote>\n<p>curl -X &#8220;DELETE&#8221;\u00a0&#8220;https:\/\/testaccount.timetrackenterprise.com\/api\/v2\/ext\/tasks\/1&#8221;<br \/>\n-H &#8216;Content-Type: application\/json&#8217;<br \/>\n-H &#8216;X-TimeTrack-Api-Secret: &lt;<em>API_SECRET_TOKEN&gt;<\/em>&#8216;<br \/>\n-H &#8216;X-TimeTrack-Api-Key: &lt;<em>API_KEY&gt;<\/em>&#8216;<br \/>\n-d $'{}&#8217;<\/p>\n<\/blockquote>\n<\/div><\/section><\/div><\/p>\n\n<style type=\"text\/css\" data-created_by=\"avia_inline_auto\" id=\"style-css-av-kguof6g6-97f8f79cefbcca3ddbdec2b8541426be\">\n.flex_column.av-kguof6g6-97f8f79cefbcca3ddbdec2b8541426be{\nborder-radius:0px 0px 0px 0px;\npadding:0px 0px 0px 0px;\n}\n<\/style>\n<div  class='flex_column av-kguof6g6-97f8f79cefbcca3ddbdec2b8541426be av_one_fifth  avia-builder-el-4  el_after_av_three_fourth  avia-builder-el-last  flex_column_div av-zero-column-padding  '     ><section  class='av_textblock_section av-kguoffk6-c7fc6bdf8ba12cf48c24e35eca104db4 '   itemscope=\"itemscope\" itemtype=\"https:\/\/schema.org\/CreativeWork\" ><div class='avia_textblock'  itemprop=\"text\" ><h2>Resources<\/h2>\n<ul>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/clients\/\">Clients<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/projects\/\">Projects<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/tasks\/\">Tasks<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/project-time-entries\/\">Project Time Entries<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/expenses\/\">Expenses<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/attendance-time-entries\/\">Attendances<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/absences\/\">Absences<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/absence-types\/\">Absence Types<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/timers\/#projekt-stempeluhr\">Project Timer<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/timers\/#arbeitszeit-stempeluhr\">Attendance Timer<\/a><\/li>\n<li><a href=\"https:\/\/wpstaging.timetrackapp.com\/en\/api\/timesheets\/\">User Reports<\/a><\/li>\n<\/ul>\n<\/div><\/section><\/div>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":2,"featured_media":0,"parent":13043,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-13093","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/pages\/13093","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/comments?post=13093"}],"version-history":[{"count":0,"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/pages\/13093\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/pages\/13043"}],"wp:attachment":[{"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/media?parent=13093"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/categories?post=13093"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpstaging.timetrackapp.com\/en\/wp-json\/wp\/v2\/tags?post=13093"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}