Deel: Retrieve a timesheet
Deel timeTracking.getTimeTrackingTimesheetById: arguments, response, policy and SDK examples.
← Time tracking operations · Get started
Operation deel.timetracking_gettimetrackingtimesheetbyid
Provider route: GET /time-tracking/timesheets/{timesheet_id}. Alter supplies the connection’s credentials and routing.
Call through Alter
Section titled “Call through Alter”Install @alter-ai/sdk @alter-ai/deel with npm, or alter-sdk-deel with pip. Supply your connected customer’s grant ID and the arguments described below.
import { App } from "@alter-ai/sdk";import { DeelIntegration } from "@alter-ai/deel";
async function execute(input: Parameters<DeelIntegration["timeTracking"]["getTimeTrackingTimesheetById"]>[0]) { const app = new App({ apiKey: process.env.ALTER_API_KEY! }); try { const provider = new DeelIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! }); const call = await provider.timeTracking.getTimeTrackingTimesheetById(input); const result = await call.wait(); return result.bodyJson(); } finally { await app.close(); }}import osfrom alter_sdk import Appfrom alter_sdk_deel import DeelIntegration
async def execute(arguments): async with App(api_key=os.environ["ALTER_API_KEY"]) as app: provider = DeelIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]}) call = await provider.time_tracking.get_time_tracking_timesheet_by_id(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
path | object | Required within parent | Additional keys: not allowed |
path.timesheet_id | string | Required within parent | Format: uuid |
query | object | Optional | Additional keys: not allowed |
query.extend | string | Optional | Maximum length: 100 |
Response
Section titled “Response”Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | Model | Root | Expand Retrieve a timesheet — 200 response body |
Referenced models: Retrieve a timesheet — 200 response body
Schemas
Section titled “Schemas”Retrieve a timesheet — 200 response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
data | Model | Required within parent | Expand Retrieve a timesheet — 200 response body — data Timesheet data including validation errors if applicable. When extend=file_data, also includes file_data object with file details and download URL. |
Referenced models: Retrieve a timesheet — 200 response body — data
Retrieve a timesheet — 200 response body — data
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Timesheet data including validation errors if applicable. When extend=file_data, also includes file_data object with file details and download URL. |
contract_id | string | Required within parent | External id of the worker's contract associated with the timesheet |
created_at | string | Required within parent | Timestamp when the timesheet was created Format: date-time |
end_date | string | Required within parent | End date of the timesheet period Format: date |
file_data | JSON | Optional | Present only when `extend=file_data` is provided. Contains file details and download URL. |
file_data (anyOf 1) | Model | Alternative | Expand Retrieve a timesheet — 200 response body — data file data download url, file id, file name |
file_data (anyOf 2) | null | Alternative | |
id | string | Required within parent | Unique identifier for the timesheet Format: uuid |
review_status | string | Required within parent | Current status of the timesheet review Known values: PENDING_CREATION, PENDING_REVIEW, APPROVED, REJECTED |
start_date | string | Required within parent | Start date of the timesheet period Format: date |
submission_status | string | Required within parent | Current status of the timesheet submission Known values: UPLOADING, UPLOAD_FAILED, PROCESSING, SUBMITTED, INVALID, FAILED |
updated_at | string | Required within parent | Timestamp when the timesheet was last updated Format: date-time |
validation_errors | JSON | Required within parent | |
validation_errors (anyOf 1) | array | Alternative | Array of validation errors found during timesheet processing. Null if no errors found. |
validation_errors (anyOf 1)[] | Model | Each item | Expand Retrieve a timesheet — 200 response body — data validation errors null item |
validation_errors (anyOf 2) | null | Alternative | Array of validation errors found during timesheet processing. Null if no errors found. |
validation_errors (anyOf 2)[] | Model | Each item | Expand Retrieve a timesheet — 200 response body — data validation errors null item |
Referenced models: Retrieve a timesheet — 200 response body — data file data download url, file id, file name, Retrieve a timesheet — 200 response body — data validation errors null item
Retrieve a timesheet — 200 response body — data file data download url, file id, file name
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Present only when `extend=file_data` is provided. Contains file details and download URL. |
download_url | string | Required within parent | Pre-signed S3 URL for downloading the timesheet file Format: uri |
file_id | string | Required within parent | Unique identifier for the timesheet file Format: uuid |
file_name | string | Required within parent | Name of the timesheet file |
Retrieve a timesheet — 200 response body — data validation errors null item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
column | JSON | Optional | |
column (anyOf 1) | string | Alternative | Column name in the timesheet file where the error occurred |
column (anyOf 2) | null | Alternative | Column name in the timesheet file where the error occurred |
context | JSON | Optional | |
context (anyOf 1) | object | Alternative | Additional context information about the error Additional keys: see wildcard field |
context (anyOf 1).* | JSON | Additional keys | Any type |
context (anyOf 2) | null | Alternative | Additional context information about the error Additional keys: see wildcard field |
context (anyOf 2).* | JSON | Additional keys | Any type |
message | string | Required within parent | Human-readable error message |
row | JSON | Optional | |
row (anyOf 1) | JSON | Alternative | |
row (anyOf 1) (anyOf 1) | number | Alternative | Row number in the timesheet file where the error occurred Format: double |
row (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
row (anyOf 2) | null | Alternative | Row number in the timesheet file where the error occurred Format: double |
type | Model | Required within parent | Expand Retrieve a timesheet — 200 response body — data validation errors null item type Type of validation error |
Referenced models: Retrieve a timesheet — 200 response body — data validation errors null item type
Retrieve a timesheet — 200 response body — data validation errors null item type
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | string | Root | Type of validation error Known values: EMPTY_TIMESHEET, INVALID_TIMESHEET_FORMAT, FILE_TOO_LARGE, INVALID_FILE_TYPE, INVALID_SHIFT_TIME_ORDER, INVALID_BREAK_TIME_ORDER, BREAK_OUTSIDE_SHIFT, OVERLAPPING_BREAKS, CANNOT_SUBMIT_SHIFTS, WORK_DURATION_MISMATCH, NON_WORKING_DAY_VIOLATION, PUBLIC_HOLIDAY_VIOLATION, TIME_OFF_VIOLATION, SHIFT_OUT_OF_CYCLE, DAY_UNAVAILABLE, INVALID_SHIFT_SUBMIT_TYPE, INVALID_SHIFT_ORIGIN, INVALID_SHIFT_TYPE, INVALID_SHIFT_KEEP_IN_TOUCH_DATE_INTERVAL, OVERLAPPING_SHIFT, SHIFT_CONTRACT_IN_RESTRICTED_STATUS, SHIFT_CONTRACT_IN_TERMINATION_STATUS, SHIFT_CONTRACT_COMPLETION_DATE, SHIFT_CONTRACT_START_DATE, SHIFT_MAX_SATURDAYS_PER_YEAR_VIOLATION, INVALID_DAY_TRACKING_DATA, SHIFT_MAX_WORKING_DAYS_PER_YEAR_VIOLATION, SHIFT_MAX_CONSECUTIVE_DAYS_STREAK_VIOLATION, BREAK_TYPE_NOT_AVAILABLE, BREAK_MISSED_OR_WAIVED, BREAK_DURATION_MISMATCH, BREAK_MAX_DURATION_EXCEEDED, WORK_LOCATION_VIOLATION, WORK_LOCATION_MISMATCH_BETWEEN_TIME_CLOCK_EVENTS_FOR_SHIFT, MISSING_WORK_DESCRIPTION |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: deel.timetracking_gettimetrackingtimesheetbyid. Catalog operation: timetracking_gettimetrackingtimesheetbyid. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.
Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.
Required provider scopes: ["time-tracking:read"]
Pinned headers: {"X-Version": "2026-01-01"}