> ## Documentation Index
> Fetch the complete documentation index at: https://docs.toku.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Applying the Toku Deduction in Rippling

> How the Toku stablecoin line item is reflected on the pay run through Rippling's pay-input APIs

Each pay period, exactly one Toku line item is reflected per participating worker, using Rippling's pay-input APIs. This is the only write Toku performs against your Rippling account.

## How It's Applied

Rippling's documented write path for adding pay line items to a payroll run is its **earnings inputs** operations — list, create, and delete earnings inputs, plus **List earning types**. Rippling does not expose a public generic "create deduction" REST endpoint (deductions appear read-only inside worker payroll records), so the Toku line item is reflected on the pay run through these pay-input operations, using a dedicated earning type configured with Rippling during implementation.

Toku first matches the participating worker through the workers resource:

```bash theme={null}
curl "https://rest.ripplingapis.com/workers" \
  -H "Authorization: Bearer <access_token>"
```

Then, before each run, Toku creates the worker's earnings input on the payroll run via the **create earnings input** operation. Rippling's endpoint-level reference for the earnings-input operations requires a Rippling developer sign-in — see the [REST API documentation](https://developer.rippling.com/documentation/rest-api) to validate them.

## How the Amount Is Set

* The worker's stablecoin election in Toku determines the amount for each pay period.
* Toku recalculates and updates the pay input before each run, so one-off changes (paused elections, prorated periods) are handled automatically.
* The line item appears on the worker's pay with the Toku-dedicated earning type, so pay statements stay self-explanatory.

## Guarantees

| Behavior         | Detail                                                                |
| ---------------- | --------------------------------------------------------------------- |
| One line item    | Exactly one Toku pay input per participating worker per run           |
| No gross changes | Gross pay, taxes, and every other pay item are untouched              |
| Bounded amount   | The amount is validated against the worker's pay before it is applied |
| Reversible       | Removing a worker's election stops the line item from the next run    |

<Warning>
  Toku never modifies compensation, tax withholding, benefits, or existing pay items in Rippling — the scope of write access is limited to the Toku line item itself.
</Warning>

## Reconciliation

After the payroll run is finalized, Toku reads the worker payroll records for the run, confirms each applied Toku line item, and releases the matching on-chain stablecoin payments. Any mismatch blocks settlement and is surfaced in the Toku dashboard before funds move.

## Next

<CardGroup cols={2}>
  <Card title="Integration Overview" icon="map" href="/integrations/rippling">
    Back to the Rippling integration overview
  </Card>

  <Card title="Worker Sync" icon="users" href="/integrations/rippling/employee-sync">
    How Toku reads your worker roster
  </Card>
</CardGroup>
