# Fetching a single Time Entry

This endpoint returns structured Time Entry objects.
As with all Kantata OX API endpoints, the returned data will be referenced in sorted order in the results array
and will be indexed by ID in the time_entries top-level JSON key.
Please see our Response Format section for more information.

Endpoint: GET /time_entries/{id}
Version: 1.0.0

## Path parameters:

  - `id` (integer, required)
    The ID of the Model.

## Query parameters:

  - `include` (string)
    Any of the below associations can be included in your request by providing the include param, e.g. include=association1,association2.
- active_submission (TimesheetSubmission) - Retrieves the active timesheet (i.e. approved or pending) the time entry was submitted on, if any. The response will include active_submission_id, which references the data in the timesheet_submissions top-level key.
- external_references (ExternalReference) - Includes references to external integrations for this object.
- invoice (Invoice) - Retrieves the invoice the time entry was added to, if any. The response will include invoice_id, which references the data in the invoices top-level key.
- recent_submission (TimesheetSubmission) - Retrieves the most recent timesheet the time entry was submitted on, if any, including any rejected or cancelled timesheets. The response will include recent_submission_id, which references the data in the timesheet_submissions top-level key.
- role (Role) - Retrieves the project role of the user who performed the work for the time entry, if any. The response will include role_id, which references the data in the roles top-level key.
- story (Story) - Retrieves the task the time entry is tracked to, if any. The response will include story_id, which references the data in the stories top-level key.
- user (User) - Retrieves the user the time entry belongs to. The response will include user_id, which references the data in the users top-level key.
- workspace (Workspace) - Retrieves the project the time entry is tracked to. The response will include workspace_id, which references the data in the workspaces top-level key.

  - `optional_fields` (array)
    Allows you to request one or more optional fields as an array.
    Enum: "location_id", "user_can_edit"

## Response 200 fields (application/json):

  - `count` (integer)

  - `meta` (object)

  - `meta.count` (integer)

  - `meta.page_count` (integer)

  - `meta.page_number` (integer)

  - `meta.page_size` (integer)

  - `results` (array)

  - `results.key` (string)

  - `results.id` (string)

  - `time_entries` (object)

  - `external_references` (object)

  - `stories` (object)

  - `workspaces` (object)

  - `users` (object)

  - `timesheet_submissions` (object)

  - `invoices` (object)

  - `roles` (object)

## Response 400 fields (application/json):

  - `errors` (array)

  - `errors.type` (string)

  - `errors.message` (string)


