Skip to main content
GET
/
api
/
external
/
timesheets
List timesheet entries
curl --request GET \
  --url https://gateway-api.guardhousehq.com/api/external/timesheets \
  --header 'Authorization: Bearer <token>'
{
  "status": {
    "code": 123,
    "errorMessage": "<string>"
  },
  "data": [
    {
      "timesheetId": 123,
      "customerName": "<string>",
      "customerApiId": 123,
      "siteName": "<string>",
      "siteApiId": 123,
      "staffId": "<string>",
      "staffName": "<string>",
      "employeeId": "<string>",
      "employeeReferenceNumber": "<string>",
      "email": "jsmith@example.com",
      "mobile": "<string>",
      "subcontractorCompany": "<string>",
      "entryType": "<string>",
      "position": "<string>",
      "service": "<string>",
      "paygroup": "<string>",
      "scheduledStartTime": "2023-11-07T05:31:56Z",
      "scheduledEndTime": "2023-11-07T05:31:56Z",
      "timeclockStartTime": "2023-11-07T05:31:56Z",
      "clockInCoordinates": {},
      "timeclockBreakStartTime": "2023-11-07T05:31:56Z",
      "timeclockBreakEndTime": "2023-11-07T05:31:56Z",
      "timeclockEndTime": "2023-11-07T05:31:56Z",
      "clockOutCoordinates": {},
      "staffSubmittedTimesheetTimes": [
        {}
      ],
      "payStartTime": "2023-11-07T05:31:56Z",
      "payEndTime": "2023-11-07T05:31:56Z",
      "payBreakTime": 123,
      "invoiceStartTime": "2023-11-07T05:31:56Z",
      "invoiceEndTime": "2023-11-07T05:31:56Z",
      "invoiceBreakTime": 123,
      "notes": [
        {}
      ],
      "allowances": [
        {}
      ],
      "approvedBy": "<string>",
      "approvedDateTime": "2023-11-07T05:31:56Z",
      "customerApprovalStatus": "<string>",
      "customerApprover": "<string>",
      "customerApprovedDateTime": "2023-11-07T05:31:56Z",
      "lock": true,
      "scheduleNotes": {}
    }
  ],
  "count": 123,
  "message": "<string>",
  "errors": [
    {
      "code": 100,
      "message": "<string>"
    }
  ],
  "nextPageParameter": "<string>",
  "prevPageParameter": "<string>"
}

Authorizations

Authorization
string
header
required

JWT issued by POST /api/token/request. Send as Authorization: Bearer <token>.

Query Parameters

startDate
string<date-time>
required

Inclusive start of the date filter (UTC).

endDate
string<date-time>
required

Inclusive end of the date filter (UTC).

customerId
integer<int32>

Filter to a single customer. Omit to fall back to the customers your API key is scoped to.

siteIds
string

Comma-separated list of site IDs. Omit to fall back to the sites your API key is scoped to.

employeeId
integer<int32>

Filter to a single employee.

searchText
string

Free-text filter across timesheet ID, subcontractor name, and abbreviation.

status
enum<string>

Filter by approval state.

Available options:
Approved,
Rejected,
Pending
referenceSiteName
string

Cursor anchor when paginating across results sorted by site name.

referenceStaffName
string

Cursor anchor when paginating across results sorted by staff name.

referenceStartDate
string<date-time>

Cursor anchor when paginating across time-sorted results.

referenceId
integer<int32>

Cursor anchor ID. Pass the last incidentReportId (or equivalent) you saw to fetch the next page.

referenceName
string

Cursor anchor name when paginating across results sorted by name.

limit
integer<int32>
default:20

Maximum number of records to return.

direction
enum<string>
default:next

Cursor pagination direction. Use next to page forward and prev to page back.

Available options:
next,
prev
filter
string

Optional filter expression.

Response

Paginated list of timesheet entries

Envelope for the newer cursor-paginated endpoints (timesheets, staff, customers, sites). The cursor is encoded as a string in nextPageParameter / prevPageParameter and is intended to be POSTed back as the next request body — or appended to the query string verbatim.

status
object
data
object[]

Endpoint-specific payload. null when an error occurred.

count
integer<int32> | null
message
string
errors
object[]
nextPageParameter
string | null
prevPageParameter
string | null