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

# Funding and pulls

> When Hammock debits an employer's bank account, and for how much.

Hammock funds benefits by debiting the bank account the employer linked in hosted setup. Each
debit is a pull. Pulls are read-only: you never create one, but you can list them and listen for
their events, so the employer sees upcoming debits in your product next to its payroll funding.

```json theme={null}
{
  "id": "pull_3Vb7Nm1qWe5R",
  "object": "pull",
  "employer": "empr_1Qx8Zt2eZvKYlo2C",
  "purpose": "payroll_contributions",
  "amount": 20000,
  "currency": "usd",
  "status": "scheduled",
  "scheduled_date": "2027-03-19",
  "expected_settlement_date": "2027-03-24",
  "payroll": "pay_6Mn2Bv8cXz4L",
  "pay_date": null,
  "coverage_month": null,
  "failure_code": null
}
```

An ACH pull settles three business days after it starts.

## What triggers a pull

| Purpose | Triggered by | Sized by | Starts |
| - | - | - | - |
| `payroll_contributions` | A payroll you report | The amounts you reported | On the pay date |
| `ichra_installment` | Hammock, from the pay schedule | The employer's ICHRA allowance and premiums | Three business days before the pay date |
| `employer_contribution` | Hammock, from the plan design | A one-time employer contribution | Ahead of the contribution date |
| `account_funding` | Hammock | The level the employer's FSA funding account must hold | As needed |

Only the first is driven by your payroll report. The others are scheduled by Hammock from amounts
it already knows, and a payroll void doesn't affect them.

## Payroll contributions

When you report a payroll, Hammock pulls the money that has to reach employees' own accounts.
Not every deduction is part of that pull.

| Deduction | In the payroll pull? | Why |
| - | - | - |
| HSA, employee and employer amounts | Yes | The money goes into the employee's HSA. |
| Health FSA, limited purpose FSA | No | Card spending is paid from the employer's FSA funding account, which Hammock tops up with `account_funding` pulls. |
| Dependent care FSA | No | The employer keeps the money withheld and pays claims back through payroll as [reimbursements](https://partners.usehammock.co/guides/reimbursements.md). |
| ICHRA premium | No | It repays the employer for a premium Hammock already pulled. |

So a payroll's pull can be smaller than its `totals`, or absent.

```mermaid theme={null}
sequenceDiagram
  participant P as Your platform
  participant H as Hammock
  participant B as Employer bank
  P->>H: Report payroll on the lock date, Mar 17
  H-->>P: Event pull.created, scheduled for Mar 19
  Note over P,H: Voidable until the pull starts
  H->>B: Pull starts on the pay date, Mar 19
  H-->>P: Event pull.processing
  B-->>H: Settles on Mar 24
  H-->>P: Event pull.settled
  H-->>P: Event payroll.completed
```

## ICHRA installments

An ICHRA allowance has to be in place before the month it covers, so Hammock doesn't wait for a
payroll report. The amount comes from each employee's allowance and plan, never from what payroll
withheld.

* Each payday in a month funds part of the following month's coverage. With two paydays a month,
  the first funds half and the last funds the rest.
* The pull starts three business days before the payday, so it settles on the payday.
* Hammock schedules installments from the [pay schedule](https://partners.usehammock.co/guides/pay-schedules.md). Keep it accurate
  for employers that offer ICHRA: a stale schedule doesn't change the amount, but it does change
  the day the money moves.

| Day | What happens |
| - | - |
| Tuesday, March 16 | The installment pull starts. `pull.processing` |
| Friday, March 19 | Payday. The pull settles and the allowance is funded. `pull.settled` |
| Thursday, April 1 | The coverage month the installment paid toward begins. |

You receive `pull.created` when an installment is scheduled, which is your cue to show the
employer an upcoming debit.

## When a pull fails

A bank can return a debit, most often for insufficient funds. The pull moves to `failed` with a
`failure_code`, and you receive `pull.failed`. For a payroll pull, the payroll moves to `failed`
as well and you receive `payroll.failed`.

Hammock support works with the employer to retry. Contributions from a failed pull aren't posted
to employees' accounts until a retry settles.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.