Chilkat Online Tools

SQL Server / New FreshBooks / Time Entry Details

Back to Collection Items

-- Important: See this note about string length limitations for strings returned by sp_OAMethod calls.
--
CREATE PROCEDURE ChilkatSample
AS
BEGIN
    DECLARE @hr int
    -- Important: Do not use nvarchar(max).  See the warning about using nvarchar(max).
    DECLARE @sTmp0 nvarchar(4000)
    -- This example assumes the Chilkat API to have been previously unlocked.
    -- See Global Unlock Sample for sample code.

    DECLARE @http int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.Http', @http OUT
    IF @hr <> 0
    BEGIN
        PRINT 'Failed to create ActiveX component'
        RETURN
    END

    DECLARE @success int

    -- Adds the "Authorization: Bearer <access_token>" header.
    EXEC sp_OASetProperty @http, 'AuthToken', '<access_token>'
    EXEC sp_OAMethod @http, 'SetRequestHeader', NULL, 'Content-Type', 'application/json'

    DECLARE @sbResponseBody int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.StringBuilder', @sbResponseBody OUT

    EXEC sp_OAMethod @http, 'QuickGetSb', @success OUT, 'https://api.freshbooks.com/comments/business/{{businessId}}/time_entries/search', @sbResponseBody
    IF @success = 0
      BEGIN
        EXEC sp_OAGetProperty @http, 'LastErrorText', @sTmp0 OUT
        PRINT @sTmp0
        EXEC @hr = sp_OADestroy @http
        EXEC @hr = sp_OADestroy @sbResponseBody
        RETURN
      END

    DECLARE @jResp int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.JsonObject', @jResp OUT

    EXEC sp_OAMethod @jResp, 'LoadSb', @success OUT, @sbResponseBody
    EXEC sp_OASetProperty @jResp, 'EmitCompact', 0


    PRINT 'Response Body:'
    EXEC sp_OAMethod @jResp, 'Emit', @sTmp0 OUT
    PRINT @sTmp0

    DECLARE @respStatusCode int
    EXEC sp_OAGetProperty @http, 'LastStatus', @respStatusCode OUT

    PRINT 'Response Status Code = ' + @respStatusCode
    IF @respStatusCode >= 400
      BEGIN

        PRINT 'Response Header:'
        EXEC sp_OAGetProperty @http, 'LastHeader', @sTmp0 OUT
        PRINT @sTmp0

        PRINT 'Failed.'
        EXEC @hr = sp_OADestroy @http
        EXEC @hr = sp_OADestroy @sbResponseBody
        EXEC @hr = sp_OADestroy @jResp
        RETURN
      END

    -- Sample JSON response:
    -- (Sample code for parsing the JSON response is shown below)

    -- {
    --   "time_entries": [
    --     {
    --       "id": 47654134,
    --       "identity_id": 37256,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2016-08-16T20:00:00Z",
    --       "created_at": "2019-04-18T20:50:28Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": null,
    --       "note": "Stuff",
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47634496,
    --       "identity_id": 1882548,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2016-08-16T20:00:00Z",
    --       "created_at": "2019-04-18T15:16:32Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": null,
    --       "note": "Stuff",
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47630482,
    --       "identity_id": 1882548,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2019-04-19T04:00:00Z",
    --       "created_at": "2019-04-18T14:11:34Z",
    --       "duration": 10800,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": 3575792,
    --       "note": null,
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47630476,
    --       "identity_id": 1882548,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2019-04-15T04:00:00Z",
    --       "created_at": "2019-04-18T14:11:34Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": 3575792,
    --       "note": null,
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47654186,
    --       "identity_id": 37256,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2019-04-18T20:00:00Z",
    --       "created_at": "2019-04-18T20:51:22Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": null,
    --       "note": "Stuff",
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47630480,
    --       "identity_id": 1882548,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2019-04-18T04:00:00Z",
    --       "created_at": "2019-04-18T14:11:34Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": 3575792,
    --       "note": null,
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47630478,
    --       "identity_id": 1882548,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2019-04-17T04:00:00Z",
    --       "created_at": "2019-04-18T14:11:34Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": 3575792,
    --       "note": null,
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47632920,
    --       "identity_id": 1882548,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2016-08-16T20:00:00Z",
    --       "created_at": "2019-04-18T14:58:17Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": null,
    --       "note": "Stuff",
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     },
    --     {
    --       "id": 47632874,
    --       "identity_id": 1882548,
    --       "timer": null,
    --       "is_logged": true,
    --       "started_at": "2016-08-16T20:00:00Z",
    --       "created_at": "2019-04-18T14:57:34Z",
    --       "duration": 7200,
    --       "client_id": 31006,
    --       "project_id": 2976412,
    --       "pending_client": null,
    --       "pending_project": null,
    --       "pending_task": null,
    --       "task_id": null,
    --       "service_id": null,
    --       "note": "Stuff",
    --       "active": true,
    --       "billable": false,
    --       "billed": false,
    --       "internal": false,
    --       "retainer_id": null,
    --       "highlight": null
    --     }
    --   ],
    --   "meta": {
    --     "total": 9,
    --     "per_page": 30,
    --     "page": 1,
    --     "pages": 1,
    --     "total_logged": 0,
    --     "total_unbilled": 0
    --   },
    --   "aggregations": null,
    --   "download_token": null,
    --   "abilities": [
    --     {
    --       "time_entry_id": 47654134,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47634496,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47630482,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47630476,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47654186,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47630480,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47630478,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47632920,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     },
    --     {
    --       "time_entry_id": 47632874,
    --       "abilities": [
    --         {
    --           "name": "can_edit",
    --           "value": true
    --         },
    --         {
    --           "name": "can_delete",
    --           "value": true
    --         }
    --       ]
    --     }
    --   ]
    -- }

    -- Sample code for parsing the JSON response...
    -- Use this online tool to generate parsing code from sample JSON: Generate JSON Parsing Code

    DECLARE @id int

    DECLARE @identity_id int

    DECLARE @timer nvarchar(4000)

    DECLARE @is_logged int

    DECLARE @started_at nvarchar(4000)

    DECLARE @created_at nvarchar(4000)

    DECLARE @duration int

    DECLARE @client_id int

    DECLARE @project_id int

    DECLARE @pending_client nvarchar(4000)

    DECLARE @pending_project nvarchar(4000)

    DECLARE @pending_task nvarchar(4000)

    DECLARE @task_id nvarchar(4000)

    DECLARE @service_id nvarchar(4000)

    DECLARE @note nvarchar(4000)

    DECLARE @active int

    DECLARE @billable int

    DECLARE @billed int

    DECLARE @internal int

    DECLARE @retainer_id nvarchar(4000)

    DECLARE @highlight nvarchar(4000)

    DECLARE @time_entry_id int

    DECLARE @j int

    DECLARE @count_j int

    DECLARE @name nvarchar(4000)

    DECLARE @value int

    DECLARE @Total int
    EXEC sp_OAMethod @jResp, 'IntOf', @Total OUT, 'meta.total'
    DECLARE @Per_page int
    EXEC sp_OAMethod @jResp, 'IntOf', @Per_page OUT, 'meta.per_page'
    DECLARE @Page int
    EXEC sp_OAMethod @jResp, 'IntOf', @Page OUT, 'meta.page'
    DECLARE @Pages int
    EXEC sp_OAMethod @jResp, 'IntOf', @Pages OUT, 'meta.pages'
    DECLARE @Total_logged int
    EXEC sp_OAMethod @jResp, 'IntOf', @Total_logged OUT, 'meta.total_logged'
    DECLARE @Total_unbilled int
    EXEC sp_OAMethod @jResp, 'IntOf', @Total_unbilled OUT, 'meta.total_unbilled'
    DECLARE @aggregations nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @aggregations OUT, 'aggregations'
    DECLARE @download_token nvarchar(4000)
    EXEC sp_OAMethod @jResp, 'StringOf', @download_token OUT, 'download_token'
    DECLARE @i int
    SELECT @i = 0
    DECLARE @count_i int
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'time_entries'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'IntOf', @id OUT, 'time_entries[i].id'
        EXEC sp_OAMethod @jResp, 'IntOf', @identity_id OUT, 'time_entries[i].identity_id'
        EXEC sp_OAMethod @jResp, 'StringOf', @timer OUT, 'time_entries[i].timer'
        EXEC sp_OAMethod @jResp, 'BoolOf', @is_logged OUT, 'time_entries[i].is_logged'
        EXEC sp_OAMethod @jResp, 'StringOf', @started_at OUT, 'time_entries[i].started_at'
        EXEC sp_OAMethod @jResp, 'StringOf', @created_at OUT, 'time_entries[i].created_at'
        EXEC sp_OAMethod @jResp, 'IntOf', @duration OUT, 'time_entries[i].duration'
        EXEC sp_OAMethod @jResp, 'IntOf', @client_id OUT, 'time_entries[i].client_id'
        EXEC sp_OAMethod @jResp, 'IntOf', @project_id OUT, 'time_entries[i].project_id'
        EXEC sp_OAMethod @jResp, 'StringOf', @pending_client OUT, 'time_entries[i].pending_client'
        EXEC sp_OAMethod @jResp, 'StringOf', @pending_project OUT, 'time_entries[i].pending_project'
        EXEC sp_OAMethod @jResp, 'StringOf', @pending_task OUT, 'time_entries[i].pending_task'
        EXEC sp_OAMethod @jResp, 'StringOf', @task_id OUT, 'time_entries[i].task_id'
        EXEC sp_OAMethod @jResp, 'StringOf', @service_id OUT, 'time_entries[i].service_id'
        EXEC sp_OAMethod @jResp, 'StringOf', @note OUT, 'time_entries[i].note'
        EXEC sp_OAMethod @jResp, 'BoolOf', @active OUT, 'time_entries[i].active'
        EXEC sp_OAMethod @jResp, 'BoolOf', @billable OUT, 'time_entries[i].billable'
        EXEC sp_OAMethod @jResp, 'BoolOf', @billed OUT, 'time_entries[i].billed'
        EXEC sp_OAMethod @jResp, 'BoolOf', @internal OUT, 'time_entries[i].internal'
        EXEC sp_OAMethod @jResp, 'StringOf', @retainer_id OUT, 'time_entries[i].retainer_id'
        EXEC sp_OAMethod @jResp, 'StringOf', @highlight OUT, 'time_entries[i].highlight'
        SELECT @i = @i + 1
      END
    SELECT @i = 0
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'abilities'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'IntOf', @time_entry_id OUT, 'abilities[i].time_entry_id'
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'abilities[i].abilities'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @name OUT, 'abilities[i].abilities[j].name'
            EXEC sp_OAMethod @jResp, 'BoolOf', @value OUT, 'abilities[i].abilities[j].value'
            SELECT @j = @j + 1
          END
        SELECT @i = @i + 1
      END

    EXEC @hr = sp_OADestroy @http
    EXEC @hr = sp_OADestroy @sbResponseBody
    EXEC @hr = sp_OADestroy @jResp


END
GO

Curl Command

curl -X GET
	-H "Authorization: Bearer <access_token>"
	-H "Content-Type: application/json"
https://api.freshbooks.com/comments/business/{{businessId}}/time_entries/search

Postman Collection Item JSON

{
  "name": "Time Entry Details",
  "request": {
    "method": "GET",
    "header": [
      {
        "key": "Content-Type",
        "value": "application/json",
        "type": "text",
        "disabled": true
      }
    ],
    "url": {
      "raw": "https://api.freshbooks.com/comments/business/{{businessId}}/time_entries/search",
      "protocol": "https",
      "host": [
        "api",
        "freshbooks",
        "com"
      ],
      "path": [
        "comments",
        "business",
        "{{businessId}}",
        "time_entries",
        "search"
      ],
      "query": [
        {
          "key": "group_by",
          "value": "clients",
          "description": "Group by clients, vendor, ",
          "disabled": true
        },
        {
          "key": "include_jwt",
          "value": "true",
          "description": "Boolean, includes JWT token if true. ",
          "disabled": true
        },
        {
          "key": "timezone",
          "value": "America%2FToronto",
          "disabled": true
        },
        {
          "key": "billable",
          "value": "1",
          "disabled": true
        },
        {
          "key": "billed",
          "value": "1",
          "disabled": true
        },
        {
          "key": "project_id",
          "value": "2980874",
          "description": "Filter by Project using `project_id`",
          "disabled": true
        },
        {
          "key": "identity_id",
          "value": "37256",
          "description": "Filter by Staff using `identity_id`",
          "disabled": true
        },
        {
          "key": "date_gte",
          "value": "2019-03-01T05%3A00%3A00Z",
          "disabled": true
        },
        {
          "key": "date_lte",
          "value": "2019-04-01T03%3A59%3A59Z",
          "disabled": true
        },
        {
          "key": "sort",
          "value": "-started_at",
          "disabled": true
        }
      ]
    },
    "description": "A detailed summary of how much time you and/or your team tracked over a period of time. \n\n*Reminder to not use `Content-Type` when calling for time-entry details*"
  },
  "response": [
    {
      "name": "Time Entry Details",
      "originalRequest": {
        "method": "GET",
        "header": [
          {
            "key": "Content-Type",
            "value": "application/json",
            "type": "text",
            "disabled": true
          }
        ],
        "url": {
          "raw": "https://api.freshbooks.com/comments/business/{{businessId}}/time_entries/search",
          "protocol": "https",
          "host": [
            "api",
            "freshbooks",
            "com"
          ],
          "path": [
            "comments",
            "business",
            "{{businessId}}",
            "time_entries",
            "search"
          ],
          "query": [
            {
              "key": "group_by",
              "value": "clients",
              "description": "Group by clients, vendor, ",
              "disabled": true
            },
            {
              "key": "include_jwt",
              "value": "true",
              "description": "Boolean, includes JWT token if true. ",
              "disabled": true
            },
            {
              "key": "timezone",
              "value": "America%2FToronto",
              "disabled": true
            },
            {
              "key": "billable",
              "value": "1",
              "disabled": true
            },
            {
              "key": "billed",
              "value": "1",
              "disabled": true
            },
            {
              "key": "project_id",
              "value": "2980874",
              "description": "Filter by Project using `project_id`",
              "disabled": true
            },
            {
              "key": "identity_id",
              "value": "37256",
              "description": "Filter by Staff using `identity_id`",
              "disabled": true
            },
            {
              "key": "date_gte",
              "value": "2019-03-01T05%3A00%3A00Z",
              "disabled": true
            },
            {
              "key": "date_lte",
              "value": "2019-04-01T03%3A59%3A59Z",
              "disabled": true
            },
            {
              "key": "sort",
              "value": "-started_at",
              "disabled": true
            }
          ]
        }
      },
      "status": "OK",
      "code": 200,
      "_postman_previewlanguage": "json",
      "header": [
        {
          "key": "Server",
          "value": "nginx"
        },
        {
          "key": "Content-Type",
          "value": "application/vnd.api+json"
        },
        {
          "key": "X-Version",
          "value": "1904.25.0"
        },
        {
          "key": "X-NewRelic-App-Data",
          "value": "PxQBWV5TCBABVllUBAQOU10TGhE1AwE2QgNWEVlbQFtcCxYnRA9QFg1ZWU4FDFZFVRYSBxlDUhULRERQBxVNFlkPXT1dVkBAWgBKPkIEUhAHXhkTAxBXRkIHBFhDWFoDO1RYRxAPBhFvEV0DSltcEB9VFVEfUANRUQcOVVVaDgoHVldXAQMbS1UdFFZUUlUHVlJaUQsJBFZWV11DHQdSDhdTag=="
        },
        {
          "key": "Access-Control-Allow-Origin",
          "value": "*"
        },
        {
          "key": "Expires",
          "value": "Tue, 24 Apr 2018 18:32:22 GMT"
        },
        {
          "key": "Cache-Control",
          "value": "no-cache"
        },
        {
          "key": "Via",
          "value": "1.1 google"
        },
        {
          "key": "Via",
          "value": "1.1 varnish"
        },
        {
          "key": "Accept-Ranges",
          "value": "bytes"
        },
        {
          "key": "Accept-Ranges",
          "value": "bytes"
        },
        {
          "key": "Age",
          "value": "0"
        },
        {
          "key": "Age",
          "value": "0"
        },
        {
          "key": "Content-Length",
          "value": "5298"
        },
        {
          "key": "Date",
          "value": "Wed, 24 Apr 2019 18:32:22 GMT"
        },
        {
          "key": "Connection",
          "value": "keep-alive"
        },
        {
          "key": "X-Served-By",
          "value": "cache-mdw17369-MDW"
        },
        {
          "key": "X-Cache",
          "value": "MISS"
        },
        {
          "key": "X-Cache-Hits",
          "value": "0"
        },
        {
          "key": "Country",
          "value": "CA"
        },
        {
          "key": "Strict-Transport-Security",
          "value": "max-age=31536000; includeSubDomains; preload"
        }
      ],
      "cookie": [
      ],
      "body": "{\n    \"time_entries\": [\n        {\n            \"id\": 47654134,\n            \"identity_id\": 37256,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2016-08-16T20:00:00Z\",\n            \"created_at\": \"2019-04-18T20:50:28Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": null,\n            \"note\": \"Stuff\",\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47634496,\n            \"identity_id\": 1882548,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2016-08-16T20:00:00Z\",\n            \"created_at\": \"2019-04-18T15:16:32Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": null,\n            \"note\": \"Stuff\",\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47630482,\n            \"identity_id\": 1882548,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2019-04-19T04:00:00Z\",\n            \"created_at\": \"2019-04-18T14:11:34Z\",\n            \"duration\": 10800,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": 3575792,\n            \"note\": null,\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47630476,\n            \"identity_id\": 1882548,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2019-04-15T04:00:00Z\",\n            \"created_at\": \"2019-04-18T14:11:34Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": 3575792,\n            \"note\": null,\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47654186,\n            \"identity_id\": 37256,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2019-04-18T20:00:00Z\",\n            \"created_at\": \"2019-04-18T20:51:22Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": null,\n            \"note\": \"Stuff\",\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47630480,\n            \"identity_id\": 1882548,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2019-04-18T04:00:00Z\",\n            \"created_at\": \"2019-04-18T14:11:34Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": 3575792,\n            \"note\": null,\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47630478,\n            \"identity_id\": 1882548,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2019-04-17T04:00:00Z\",\n            \"created_at\": \"2019-04-18T14:11:34Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": 3575792,\n            \"note\": null,\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47632920,\n            \"identity_id\": 1882548,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2016-08-16T20:00:00Z\",\n            \"created_at\": \"2019-04-18T14:58:17Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": null,\n            \"note\": \"Stuff\",\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        },\n        {\n            \"id\": 47632874,\n            \"identity_id\": 1882548,\n            \"timer\": null,\n            \"is_logged\": true,\n            \"started_at\": \"2016-08-16T20:00:00Z\",\n            \"created_at\": \"2019-04-18T14:57:34Z\",\n            \"duration\": 7200,\n            \"client_id\": 31006,\n            \"project_id\": 2976412,\n            \"pending_client\": null,\n            \"pending_project\": null,\n            \"pending_task\": null,\n            \"task_id\": null,\n            \"service_id\": null,\n            \"note\": \"Stuff\",\n            \"active\": true,\n            \"billable\": false,\n            \"billed\": false,\n            \"internal\": false,\n            \"retainer_id\": null,\n            \"highlight\": null\n        }\n    ],\n    \"meta\": {\n        \"total\": 9,\n        \"per_page\": 30,\n        \"page\": 1,\n        \"pages\": 1,\n        \"total_logged\": 0,\n        \"total_unbilled\": 0\n    },\n    \"aggregations\": null,\n    \"download_token\": null,\n    \"abilities\": [\n        {\n            \"time_entry_id\": 47654134,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47634496,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47630482,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47630476,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47654186,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47630480,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47630478,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47632920,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        },\n        {\n            \"time_entry_id\": 47632874,\n            \"abilities\": [\n                {\n                    \"name\": \"can_edit\",\n                    \"value\": true\n                },\n                {\n                    \"name\": \"can_delete\",\n                    \"value\": true\n                }\n            ]\n        }\n    ]\n}"
    }
  ]
}