Skip to content

Deel: Process time-off requests from an external HRIS

Deel timeOff.syncTimeOffGlobalPayroll: arguments, response, policy and SDK examples.

← Time off operations · Get started

Operation deel.timeoff_synctimeoffglobalpayroll

Provider route: POST /time_offs/global-payroll/sync. Alter supplies the connection’s credentials and routing.

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["timeOff"]["syncTimeOffGlobalPayroll"]>[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.timeOff.syncTimeOffGlobalPayroll(input);
const result = await call.wait();
return result.bodyJson();
} finally {
await app.close();
}
}
import os
from alter_sdk import App
from 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_off.sync_time_off_global_payroll(arguments)
result = await call.wait()
return result.body_json()
FieldTypePresenceDescription and constraints
$objectRootAdditional keys: not allowed
bodyobjectOptional
body.dataModelOptionalExpand Process time-off requests from an external HRIS — request body — body data

Referenced models: Process time-off requests from an external HRIS — request body — body data

Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.

FieldTypePresenceDescription and constraints
$ModelRootExpand Process time-off requests from an external HRIS — 200 response body

Referenced models: Process time-off requests from an external HRIS — 200 response body

Process time-off requests from an external HRIS — 200 response body
FieldTypePresenceDescription and constraints
$objectRootList of time offs persisted at Deel
dataModelOptionalExpand Process time-off requests from an external HRIS — 200 response body — data

Referenced models: Process time-off requests from an external HRIS — 200 response body — data

Process time-off requests from an external HRIS — request body — body data
FieldTypePresenceDescription and constraints
$objectRoot
time_offsarrayRequired within parent
time_offs[]ModelEach itemExpand Process time-off requests from an external HRIS — request body — body data time offs item

Referenced models: Process time-off requests from an external HRIS — request body — body data time offs item

Process time-off requests from an external HRIS — 200 response body — data
FieldTypePresenceDescription and constraints
$objectRoot
deletedJSONOptional
deleted (anyOf 1)numberAlternativeNumber of time off requests that were deleted
Format: double
deleted (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
insertedJSONOptional
inserted (anyOf 1)numberAlternativeNumber of time off requests that were inserted
Format: double
inserted (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
updatedJSONOptional
updated (anyOf 1)numberAlternativeNumber of time off requests that were updated
Format: double
updated (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
Process time-off requests from an external HRIS — request body — body data time offs item
FieldTypePresenceDescription and constraints
$JSONRoot
$ (oneOf 1)ModelAlternativeExpand Process time-off requests from an external HRIS — request body — body / data / time_offs / item / entitlement_unit: HOUR, BUSINESS DAY, CALENDAR DAY, WEEK, MONTH, YEAR
$ (oneOf 2)ModelAlternativeExpand Process time-off requests from an external HRIS — request body — body data time offs item contract oid, deleted, external id

Referenced models: Process time-off requests from an external HRIS — request body — body / data / time_offs / item / entitlement_unit: HOUR, BUSINESS DAY, CALENDAR DAY, WEEK, MONTH, YEAR, Process time-off requests from an external HRIS — request body — body data time offs item contract oid, deleted, external id

Process time-off requests from an external HRIS — request body — body / data / time_offs / item / entitlement_unit: HOUR, BUSINESS DAY, CALENDAR DAY, WEEK, MONTH, YEAR
FieldTypePresenceDescription and constraints
$objectRoot
amountstringOptionalThe amount in time units for this time off. When no amount is informed, it will be calculated using work schedules and public holidays defined at Deel.
approved_atstringOptionalThe approval date of the time off. If no approval date is informed, the start date of this request will be used as the approval date. Note: use this field in order to support retrospective leaves so Deel can identify requests made after the payroll cycle.
Format: date
contract_oidstringRequired within parentThe contract id that has requested the time off.
Maximum length: 24
descriptionstring or nullOptionalThe description of the time off.
Maximum length: 500
end_datestringRequired within parentThe end date of the time off.
Format: date
entitlement_unitstringOptionalThe time unit for this time off. *Mandatory when amount parameter is informed*. If no amount and no entitlement_unit are informed, it will be calculated using Deel's internal country templates for compliant time off policies.
One of: HOUR, BUSINESS_DAY, CALENDAR_DAY, WEEK, MONTH, YEAR
external_idstringRequired within parentExternal ID to link a Deel time off object with an external time off object. It will be used to determine which operation should be done: INSERT, UPDATE or DELETE.
Maximum length: 48
is_paidbooleanOptionalAllows the consumer to specify whether the time off is considered as paid (at statutory) or unpaid based on the configuration of the policy in the external HRIS.
policy_namestringOptionalThe policy name the time off is being requested for. If not informed, a default name will be generated using the policy type and contract's country (eg: Vacation - US).
Maximum length: 256
policy_typeJSONRequired within parentThe Deel policy type of the policy the time off is being requested for.
policy_type (oneOf 1)ModelAlternativeExpand Process time-off requests from an external HRIS — request body — body / data / time_offs / item / entitlement_unit: HOUR, BUSINESS DAY, CALENDAR DAY, WEEK, MONTH, YEAR policy type string
policy_type (oneOf 2)nullAlternative
requested_atstringOptionalThe request date of the time off.
Format: date
start_datestringRequired within parentThe start date of the time off.
Format: date

Referenced models: Process time-off requests from an external HRIS — request body — body / data / time_offs / item / entitlement_unit: HOUR, BUSINESS DAY, CALENDAR DAY, WEEK, MONTH, YEAR policy type string

Process time-off requests from an external HRIS — request body — body data time offs item contract oid, deleted, external id
FieldTypePresenceDescription and constraints
$objectRoot
contract_oidstringRequired within parentThe contract id that has requested the time off.
Maximum length: 24
deletedbooleanRequired within parentIndicates this time off request must be deleted
external_idstringRequired within parentExternal ID to link a Deel time off object with an external time off object. It will be used to determine which operation should be done: INSERT, UPDATE or DELETE.
Maximum length: 48
Process time-off requests from an external HRIS — request body — body / data / time_offs / item / entitlement_unit: HOUR, BUSINESS DAY, CALENDAR DAY, WEEK, MONTH, YEAR policy type string
FieldTypePresenceDescription and constraints
$stringRootThe Deel policy type of the policy the time off is being requested for.
One of: Adoption leave, Advanced vacation, Bereaved partner's paternity leave, Bereavement leave, Blood donation leave, Breastfeeding leave, Carer's leave, Childbirth leave, Childcare leave, Civic/public duty leave, Compensatory leave, Disability leave, Doctor's appointment leave, Family & domestic violence leave, Family responsibility leave, Floating Holiday Allowance, Hajj leave, Hospitalization leave, Long Service Leave, Marriage/wedding leave, Maternity leave, Menstrual leave, Military leave, Moving leave, Neonatal care leave, Other leave, Paid leave, Parental bereavement leave, Parental leave, Paternity leave, Personal leave, Pregnancy leave, Regional holiday, RTT, Shared parental leave, Sick leave, Strike, Study leave, Supplementary Leave, Unpaid leave, Vacation, Vacation - public holidays replacement, Volunteer leave, Work accident leave, Work away from office, Work Location

SDK function policy ID: deel.timeoff_synctimeoffglobalpayroll. Catalog operation: timeoff_synctimeoffglobalpayroll. 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-off:write"]

Pinned headers: {"X-Version": "2026-01-01"}

Official provider source

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand which product and documentation features are useful.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

You can change these choices at any time from Cookie settings.