settleTerminatedRailWithoutValidation
settleTerminatedRailWithoutValidation(
client,options):Promise<`0x${string}`>
Defined in: packages/synapse-core/src/pay/settle-terminated-rail-without-validation.ts:68
Settle a terminated payment rail without validation
Emergency settlement for terminated rails only - bypasses service contract validation. This ensures payment even if the validator contract is buggy or unresponsive (pays in full). Can only be called by the client after the max settlement epoch has passed.
Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
client | Client<Transport, Chain, Account> | The viem client with account to use for the transaction. |
options | OptionsType | settleTerminatedRailWithoutValidation.OptionsType |
Returns
Section titled “Returns”Promise<`0x${string}`>
The transaction hash
Throws
Section titled “Throws”Errors settleTerminatedRailWithoutValidation.ErrorType
Example
Section titled “Example”import { settleTerminatedRailWithoutValidation } from '@filoz/synapse-core/pay'import { createWalletClient, http } from 'viem'import { privateKeyToAccount } from 'viem/accounts'import { calibration } from '@filoz/synapse-core/chains'
const account = privateKeyToAccount('0x...')const client = createWalletClient({ account, chain: calibration, transport: http(),})
// Settle terminated railconst hash = await settleTerminatedRailWithoutValidation(client, { railId: 1n,})
console.log(hash)