# z.RpcSchema.parseItem

Looks up the `RpcSchema.Item` for a method on a namespace. Resolve a method once and pass the item to the `decode*`/`encode*` codecs to encode params and decode returns without repeating the namespace and method name.

## Imports

```ts
import { z } from 'ox/zod'

z.RpcSchema.parseItem
```

## Examples

```ts twoslash
import { z } from 'ox/zod'

const item = z.RpcSchema.parseItem(
  z.RpcSchema.Eth,
  'eth_getBlockTransactionCountByNumber'
)

const params = z.RpcSchema.encodeParams(item, [1n])
const count = z.RpcSchema.decodeReturns(item, '0x1')
```

## Definition

```ts
export declare function parseItem<const namespace extends Namespace, method extends MethodName<namespace>>(namespace: namespace, method: method): namespace[method];
```

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `namespace` | `namespace` |  |
| `method` | `method` |  |

## Return Type

`namespace[method]`

**Source:** [src/zod/RpcSchema.ts](https://github.com/wevm/ox/blob/main/src/zod/RpcSchema.ts#L454)
