# parseGetRailsForPayeeAndToken

> **parseGetRailsForPayeeAndToken**(`data`): [`OutputType`](/reference/filoz/synapse-core/pay/namespaces/getrailsforpayeeandtoken/type-aliases/outputtype/)

Defined in: [packages/synapse-core/src/pay/get-rails-for-payee-and-token.ts:168](https://github.com/FilOzone/synapse-sdk/blob/aaa98045b003ec23f4318ba9a3032a434e5a20c9/packages/synapse-core/src/pay/get-rails-for-payee-and-token.ts#L168)

Parse raw payee-rail contract output into a normalized page with a total.

The contract's `results` tuple is mapped to `items`, including finalized and
skipped rail slots. `nextOffset` becomes `nextCursor` only when it is less
than `total`; `total` is the underlying rail-slot count.

## Parameters

| Parameter | Type | Description |
| ------ | ------ | ------ |
| `data` | readonly \[readonly `object`[], `bigint`, `bigint`\] | Raw contract output [getRailsForPayeeAndToken.ContractOutputType](/reference/filoz/synapse-core/pay/namespaces/getrailsforpayeeandtoken/type-aliases/contractoutputtype/) |

## Returns

[`OutputType`](/reference/filoz/synapse-core/pay/namespaces/getrailsforpayeeandtoken/type-aliases/outputtype/)

A normalized rail page [getRailsForPayeeAndToken.OutputType](/reference/filoz/synapse-core/pay/namespaces/getrailsforpayeeandtoken/type-aliases/outputtype/)