Deel: Calculate Employee Costs Globally
Deel costCalculator.getEmploymentCost: arguments, response, policy and SDK examples.
← Cost calculator operations · Get started
Operation deel.costcalculator_getemploymentcost
Provider route: POST /eor/employment_cost. 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["costCalculator"]["getEmploymentCost"]>[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.costCalculator.getEmploymentCost(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.cost_calculator.get_employment_cost(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
body | object | Optional | |
body.data | Model | Required within parent | Expand Calculate Employee Costs Globally — request body — body data |
Referenced models: Calculate Employee Costs Globally — request body — body data
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 Calculate Employee Costs Globally — 200 response body |
Referenced models: Calculate Employee Costs Globally — 200 response body
Schemas
Section titled “Schemas”Calculate Employee Costs Globally — request body — body data
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
benefits | array or null | Optional | A list of selected benefit plans for the employee. |
benefits[] | Model | Each item | Expand Calculate Employee Costs Globally — request body — body data benefits item |
country | string | Required within parent | The full name of the country where the employee is based. |
country_code | string | Optional | The two-letter country code where the employee is based. |
currency | string | Required within parent | The currency in which the costs are calculated. |
salary | number | Required within parent | The base salary for the employee. Format: double Minimum: 1 |
salary_period | string | Optional | The salary period for the amount provided. Default: ANNUALLY One of: ANNUALLY, MONTHLY |
state | string | Optional | The state or region within the country, if applicable. |
Referenced models: Calculate Employee Costs Globally — request body — body data benefits item
Calculate Employee Costs Globally — 200 response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
additional_data | Model | Optional | Expand Calculate Employee Costs Globally — 200 response body — additional data |
benefits_data | array | Optional | |
benefits_data[] | Model | Each item | Expand Calculate Employee Costs Globally — 200 response body — benefits data item |
costs | array | Optional | |
costs[] | Model | Each item | Expand Calculate Employee Costs Globally — 200 response body — costs item |
country | string | Optional | The country where the employee is based. |
country_code | string | Optional | ISO Alpha-2 code of the country. |
currency | string | Optional | The currency used for cost calculation. |
deel_fee | string | Optional | The Deel fee for managing the employee. |
employer_annual_costs | string | Optional | Costs incurred by the employer for cost items with an annual payment frequency. |
employer_costs | string | Optional | Costs incurred by the employer. |
employer_costs_usd | string | Optional | Costs incurred by the employer, converted to USD. |
frequency | string | Optional | Frequency of the salary payment (e.g., monthly). |
salary | string | Optional | The base salary for the employee. |
severance_accural | string | Optional | Severance accrual costs. |
severance_accural_usd | string | Optional | Severance accrual costs, converted to USD. |
total_costs | string | Optional | Total employment costs. |
Referenced models: Calculate Employee Costs Globally — 200 response body — additional data, Calculate Employee Costs Globally — 200 response body — benefits data item, Calculate Employee Costs Globally — 200 response body — costs item
Calculate Employee Costs Globally — request body — body data benefits item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
plan_id | string or null | Optional | The ID of the benefits plan, if applicable. |
provider_id | string | Required within parent | The ID of the benefits provider. |
Calculate Employee Costs Globally — 200 response body — additional data
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
additional_notes | array | Optional | |
additional_notes[] | string | Each item |
Calculate Employee Costs Globally — 200 response body — benefits data item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
amount | string | Optional | Benefit cost. |
fee_amount | string | Optional | Fees associated with the benefit. |
name | string | Optional | Benefit name. |
plan | string | Optional | Benefit plan. |
Calculate Employee Costs Globally — 200 response body — costs item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
amount | string | Optional | Cost amount. |
country | string | Optional | The country of the cost item. |
country_code | string | Optional | ISO Alpha-2 code of the country. |
frequency | string | Optional | The frequency of the cost (e.g., monthly, annually). |
name | string | Optional | Name of the cost item. |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: deel.costcalculator_getemploymentcost. Catalog operation: costcalculator_getemploymentcost. 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.
Pinned headers: {"X-Version": "2026-01-01"}