Triggers a formal batch distribution through the PayrollBatcher pulling funds directly from the employer Treasury. EndpointDocumentation Index
Fetch the complete documentation index at: https://docs.remlo.xyz/llms.txt
Use this file to discover all available pages before exploring further.
POST /api/mpp/payroll/execute
Pricing
$1.00 per call — Represents a high-value state-changing transaction acting as a massive operational shortcut.
Payment type
Single charge — A dedicated endpoint to trigger one massive distribution event for the entire employee registry.
Request
availableBalance is less than the requested total_amount, the execution will fail and revert, but the $1.00 API access charge is still settled due to processing costs. Ensure preflight checks on treasury health before execution.
Authorization
Caller must be the employer that owns the payroll run, proven by either:- Privy bearer token —
Authorization: Bearer <privy_jwt>whosesubmatchesemployers.owner_user_id. - Tier 1 agent —
X-Agent-Identifier+X-Agent-Timestamp+X-Agent-Signature(HMAC). - Tier 2 agent —
X-Agent-Identifier: erc8004:tempo:<agentId>+ signed canonical message.
Side effects
After the on-chain transaction is broadcast, three async actions fire (fire-and-forget; handler latency is not extended):- Employer notification — a
payroll_finalizedrow is inserted intonotificationsfor the dashboard bell. - Employer email —
PayrollFinalizedEmailtemplate fires once per run to the employer’s billing email, summarizing recipient count, total, chain, tx hash. - Per-employee receipts — for each
payment_itemin the run that has anemailon file, aPaymentReceivedEmailfires to the employee. The receipt includes the amount, settlement timestamp, chain, tx hash, payslip link, and an off-ramp hint. Idempotency keys are scoped to(run_id, employee_id)so retried executions don’t double-send. Recipients on the suppression list (prior bounce or complaint) are filtered out.
/api/employers/{id}/payroll/{runId}/execute (Privy-authed) variant.