import { APIResource } from "../core/resource.mjs"; import * as BusinessPartnersAPI from "./business-partners.mjs"; import { APIPromise } from "../core/api-promise.mjs"; import { PageCursorURL, PagePromise } from "../core/pagination.mjs"; import { RequestOptions } from "../internal/request-options.mjs"; /** * Compensation associated with workers */ export declare class VariableCompensationPayouts extends APIResource { /** * List variable compensation payouts. Paginated with limit and cursor. Filters use * the documented query parameters only (not OData filter). Always uses the company * admin payout rowset; callers without admin payout visibility receive an empty * list. Retrieve returns NotFound for the same rows. * * - Requires: `Variable Compensation Scheduled Payouts API` * * @example HTTP * Representative request and response shapes. * ``` * GET /variable-compensation-payouts/?limit=0&cursor=cursor&payee_id=payee_id&client=VC_PLAN_CYCLE&external_id=external_id&status=DRAFT&source_label_id=source_label_id&group_label_id=group_label_id HTTP/1.1 * Host: rest.ripplingapis.com * Accept: application/json * Rippling-Api-Version: 2024-08-01 * * HTTP/1.1 200 OK * Content-Type: application/json * * { * "__meta": { * "redacted_fields": [ * { * "name": "date_of_birth", * "reason": "Insufficient entitlements" * } * ] * }, * "results": [ * { * "id": "string", * "payee_id": "string", * "client": "VC_PLAN_CYCLE", * "external_id": "string", * "amount_base": { * "currency_type": "string", * "value": "string" * }, * "amount_usd": { * "currency_type": "string", * "value": "string" * }, * "pay_classification": "string", * "payout_type": "string", * "scheduled_date": "string", * "effective_start_date": "string", * "effective_end_date": "string", * "name": "string", * "description": "string", * "status": "DRAFT", * "cancel_reason": "string", * "source_label_id": "string", * "group_label_id": "string", * "paystub_id": "string", * "created_at": "string", * "updated_at": "string" * } * ], * "next_link": "string" * } * ``` */ list(query?: VariableCompensationPayoutListParams | null | undefined, options?: RequestOptions): PagePromise; /** * Create or update one payout. Identity is (client, external_id), not id. Same key * and same body replays with 200. Same key and a different body overwrites a * SCHEDULED row when the caller can edit scheduled payouts; otherwise 403. * RELEASED rows return 409. New identities return 201. This writes ledger rows; * POST /variable-compensation-payout-writes/ submits a payout into payroll. * Payroll-sync side effects (paystub_id, outbox) — VC PM / Payroll PM ack required * before GA beyond private scopes. * * @example HTTP * Representative request and response shapes. * ``` * POST /variable-compensation-payouts/ HTTP/1.1 * Host: rest.ripplingapis.com * Content-Type: application/json * Accept: application/json * Rippling-Api-Version: 2024-08-01 * * { * "amount_base": { * "currency_type": "currency_type", * "value": "value" * }, * "amount_usd": { * "currency_type": "currency_type", * "value": "value" * }, * "client": "VC_PLAN_CYCLE", * "effective_end_date": "effective_end_date", * "effective_start_date": "effective_start_date", * "external_id": "external_id", * "payee_id": "payee_id", * "payout_type": "payout_type", * "scheduled_date": "scheduled_date" * } * * HTTP/1.1 200 OK * Content-Type: application/json * * { * "id": "string", * "payee_id": "string", * "client": "VC_PLAN_CYCLE", * "external_id": "string", * "amount_base": { * "currency_type": "string", * "value": "string" * }, * "amount_usd": { * "currency_type": "string", * "value": "string" * }, * "pay_classification": "string", * "payout_type": "string", * "scheduled_date": "string", * "effective_start_date": "string", * "effective_end_date": "string", * "name": "string", * "description": "string", * "status": "DRAFT", * "cancel_reason": "string", * "source_label_id": "string", * "group_label_id": "string", * "paystub_id": "string", * "created_at": "string", * "updated_at": "string" * } * ``` */ create(body: VariableCompensationPayoutCreateParams, options?: RequestOptions): APIPromise; /** * Retrieve a specific variable compensation payout. Uses the company admin payout * rowset; callers without admin payout visibility receive NotFound. * * @example HTTP * Representative request and response shapes. * ``` * GET /variable-compensation-payouts/{id}/ HTTP/1.1 * Host: rest.ripplingapis.com * Accept: application/json * Rippling-Api-Version: 2024-08-01 * * HTTP/1.1 200 OK * Content-Type: application/json * * { * "__meta": { * "redacted_fields": [ * {} * ] * } * } * ``` */ retrieve(id: string, options?: RequestOptions): APIPromise; } export type VariableCompensationPayoutListResponsesPageCursorURL = PageCursorURL; export interface VariableCompensationPayoutListResponse { /** * Unique identifier of the payout. */ id: string; /** * Payout amount in the worker's base currency. */ amount_base: VariableCompensationPayoutListResponse.AmountBase; /** * Payout amount converted to USD. */ amount_usd: VariableCompensationPayoutListResponse.AmountUsd; /** * Client system that created the payout. */ client: 'VC_PLAN_CYCLE' | 'VC_EVENT_DRIVEN_PLAN' | 'CUSTOM' | 'MANUAL_PAYOUT' | 'HRIS_SIGN_ON' | 'OFFLINE_RECOMMENDATION'; /** * When the payout was created. */ created_at: string; /** * End date of the covered pay period. */ effective_end_date: string; /** * Start date of the covered pay period. */ effective_start_date: string; /** * External identifier unique per company and client. */ external_id: string; /** * ID of the worker who receives this payout. Expandable payee (Worker DTO + * workers.read) is deferred from v1; use GET /workers/{id}/ when needed. */ payee_id: string; /** * Key of the company payout type used for this payout. Expand is deferred from v1; * enumerate valid keys via GET /variable-compensation-payout-types/. */ payout_type: string; /** * Date on which the payout is scheduled. */ scheduled_date: string; /** * Current payout status. */ status: 'DRAFT' | 'PENDING_APPROVAL' | 'APPROVAL_REJECTED' | 'SCHEDULED' | 'RELEASED' | 'PAID' | 'FORFEITED' | 'EVALUATION_FAILED' | 'CANCELLED'; /** * When the payout was last updated. */ updated_at: string; /** * Reason provided when the payout was cancelled. */ cancel_reason?: string; /** * Optional payout description. */ description?: string; /** * Group label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ group_label_id?: string; /** * Optional payout name. */ name?: string; /** * Payroll earning code resolved from the payout type. */ pay_classification?: string; /** * Paystub identifier when the payout has been synced to payroll. */ paystub_id?: string; /** * Source label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ source_label_id?: string; } export declare namespace VariableCompensationPayoutListResponse { /** * Payout amount in the worker's base currency. */ interface AmountBase { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } /** * Payout amount converted to USD. */ interface AmountUsd { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } } export interface VariableCompensationPayoutCreateResponse { /** * Unique identifier of the payout. */ id: string; /** * Payout amount in the worker's base currency. */ amount_base: VariableCompensationPayoutCreateResponse.AmountBase; /** * Payout amount converted to USD. */ amount_usd: VariableCompensationPayoutCreateResponse.AmountUsd; /** * Client system that created the payout. */ client: 'VC_PLAN_CYCLE' | 'VC_EVENT_DRIVEN_PLAN' | 'CUSTOM' | 'MANUAL_PAYOUT' | 'HRIS_SIGN_ON' | 'OFFLINE_RECOMMENDATION'; /** * When the payout was created. */ created_at: string; /** * End date of the covered pay period. */ effective_end_date: string; /** * Start date of the covered pay period. */ effective_start_date: string; /** * External identifier unique per company and client. */ external_id: string; /** * ID of the worker who receives this payout. Expandable payee (Worker DTO + * workers.read) is deferred from v1; use GET /workers/{id}/ when needed. */ payee_id: string; /** * Key of the company payout type used for this payout. Expand is deferred from v1; * enumerate valid keys via GET /variable-compensation-payout-types/. */ payout_type: string; /** * Date on which the payout is scheduled. */ scheduled_date: string; /** * Current payout status. */ status: 'DRAFT' | 'PENDING_APPROVAL' | 'APPROVAL_REJECTED' | 'SCHEDULED' | 'RELEASED' | 'PAID' | 'FORFEITED' | 'EVALUATION_FAILED' | 'CANCELLED'; /** * When the payout was last updated. */ updated_at: string; /** * Reason provided when the payout was cancelled. */ cancel_reason?: string; /** * Optional payout description. */ description?: string; /** * Group label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ group_label_id?: string; /** * Optional payout name. */ name?: string; /** * Payroll earning code resolved from the payout type. */ pay_classification?: string; /** * Paystub identifier when the payout has been synced to payroll. */ paystub_id?: string; /** * Source label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ source_label_id?: string; } export declare namespace VariableCompensationPayoutCreateResponse { /** * Payout amount in the worker's base currency. */ interface AmountBase { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } /** * Payout amount converted to USD. */ interface AmountUsd { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } } /** * Meta information for the response. */ export interface VariableCompensationPayoutRetrieveResponse extends BusinessPartnersAPI.Meta { /** * Unique identifier of the payout. */ id: string; /** * Payout amount in the worker's base currency. */ amount_base: VariableCompensationPayoutRetrieveResponse.AmountBase; /** * Payout amount converted to USD. */ amount_usd: VariableCompensationPayoutRetrieveResponse.AmountUsd; /** * Client system that created the payout. */ client: 'VC_PLAN_CYCLE' | 'VC_EVENT_DRIVEN_PLAN' | 'CUSTOM' | 'MANUAL_PAYOUT' | 'HRIS_SIGN_ON' | 'OFFLINE_RECOMMENDATION'; /** * When the payout was created. */ created_at: string; /** * End date of the covered pay period. */ effective_end_date: string; /** * Start date of the covered pay period. */ effective_start_date: string; /** * External identifier unique per company and client. */ external_id: string; /** * ID of the worker who receives this payout. Expandable payee (Worker DTO + * workers.read) is deferred from v1; use GET /workers/{id}/ when needed. */ payee_id: string; /** * Key of the company payout type used for this payout. Expand is deferred from v1; * enumerate valid keys via GET /variable-compensation-payout-types/. */ payout_type: string; /** * Date on which the payout is scheduled. */ scheduled_date: string; /** * Current payout status. */ status: 'DRAFT' | 'PENDING_APPROVAL' | 'APPROVAL_REJECTED' | 'SCHEDULED' | 'RELEASED' | 'PAID' | 'FORFEITED' | 'EVALUATION_FAILED' | 'CANCELLED'; /** * When the payout was last updated. */ updated_at: string; /** * Reason provided when the payout was cancelled. */ cancel_reason?: string; /** * Optional payout description. */ description?: string; /** * Group label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ group_label_id?: string; /** * Optional payout name. */ name?: string; /** * Payroll earning code resolved from the payout type. */ pay_classification?: string; /** * Paystub identifier when the payout has been synced to payroll. */ paystub_id?: string; /** * Source label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ source_label_id?: string; } export declare namespace VariableCompensationPayoutRetrieveResponse { /** * Payout amount in the worker's base currency. */ interface AmountBase { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } /** * Payout amount converted to USD. */ interface AmountUsd { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } } export interface VariableCompensationPayoutListParams { /** * Client system that created the payout. */ client?: 'VC_PLAN_CYCLE' | 'VC_EVENT_DRIVEN_PLAN' | 'CUSTOM' | 'MANUAL_PAYOUT' | 'HRIS_SIGN_ON' | 'OFFLINE_RECOMMENDATION'; /** * Opaque pagination cursor from the previous page's next_link. */ cursor?: string; /** * External identifier unique per company and client. */ external_id?: string; /** * Group label identifier attached to the payout. */ group_label_id?: string; /** * Page size. Defaults to 50. Maximum 100. */ limit?: number; /** * ID of the worker who receives this payout. */ payee_id?: string; /** * Source label identifier attached to the payout. */ source_label_id?: string; /** * Current payout status. */ status?: 'DRAFT' | 'PENDING_APPROVAL' | 'APPROVAL_REJECTED' | 'SCHEDULED' | 'RELEASED' | 'PAID' | 'FORFEITED' | 'EVALUATION_FAILED' | 'CANCELLED'; } export interface VariableCompensationPayoutCreateParams { /** * Payout amount in the worker's base currency. */ amount_base: VariableCompensationPayoutCreateParams.AmountBase; /** * Payout amount converted to USD. */ amount_usd: VariableCompensationPayoutCreateParams.AmountUsd; /** * Client system that created the payout. */ client: 'VC_PLAN_CYCLE' | 'VC_EVENT_DRIVEN_PLAN' | 'CUSTOM' | 'MANUAL_PAYOUT' | 'HRIS_SIGN_ON' | 'OFFLINE_RECOMMENDATION'; /** * End date of the covered pay period. */ effective_end_date: string; /** * Start date of the covered pay period. */ effective_start_date: string; /** * External identifier unique per company and client. */ external_id: string; /** * ID of the worker who receives this payout. Expandable payee (Worker DTO + * workers.read) is deferred from v1; use GET /workers/{id}/ when needed. */ payee_id: string; /** * Key of the company payout type used for this payout. Expand is deferred from v1; * enumerate valid keys via GET /variable-compensation-payout-types/. */ payout_type: string; /** * Date on which the payout is scheduled. */ scheduled_date: string; /** * Optional payout description. */ description?: string; /** * Group label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ group_label_id?: string; /** * Optional payout name. */ name?: string; /** * Source label identifier attached to the payout. Expand is deferred from v1; use * GET /variable-compensation-payout-labels/{id}/ when needed. */ source_label_id?: string; } export declare namespace VariableCompensationPayoutCreateParams { /** * Payout amount in the worker's base currency. */ interface AmountBase { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } /** * Payout amount converted to USD. */ interface AmountUsd { /** * Three-letter currency code. */ currency_type: string; /** * Decimal amount encoded as a string. */ value: string; } } export declare namespace VariableCompensationPayouts { export { type VariableCompensationPayoutListResponse as VariableCompensationPayoutListResponse, type VariableCompensationPayoutCreateResponse as VariableCompensationPayoutCreateResponse, type VariableCompensationPayoutRetrieveResponse as VariableCompensationPayoutRetrieveResponse, type VariableCompensationPayoutListResponsesPageCursorURL as VariableCompensationPayoutListResponsesPageCursorURL, type VariableCompensationPayoutListParams as VariableCompensationPayoutListParams, type VariableCompensationPayoutCreateParams as VariableCompensationPayoutCreateParams, }; } //# sourceMappingURL=variable-compensation-payouts.d.mts.map