> **Can't find what you're looking for?** Use `search_docs` on the docs MCP server at `https://sdk.railnet.org/api/mcp` to find what you need.

# processConduitQuery

Processes a query on a conduit. Requires a `WalletClient` to sign and send the transaction.

## Import

```ts
import { processConduitQuery } from '@railnetorg/railnet-sdk'
```

## Usage

```ts
import { createWalletClient, http } from 'viem'
import { base } from 'viem/chains'
import { processConduitQuery, ConduitMode } from '@railnetorg/railnet-sdk'

const walletClient = createWalletClient({
  chain: base,
  transport: http(),
})

const hash = await processConduitQuery(walletClient, {
  conduit: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e',
  account: '0xd2135CfB216b74109775236E36d4b433F1DF507B',
  query: {
    owner: '0x...',
    receiver: '0x...',
    input: { asset: '0x...', value: 100n },
    output: { asset: '0x...', value: 100n },
    mode: ConduitMode.DEPOSIT,
    salt: '0x...',
    data: '0x',
  },
})
```

## Returns

`Hash`

The transaction hash of the process query transaction.

## Parameters

### conduit

* **Type:** `Address`

The address of the conduit contract.

```ts
const hash = await processConduitQuery(walletClient, {
  conduit: '0xA0Cf798816D4b9b9866b5330EEa46a18382f251e', // [!code focus]
  account: '0x...',
  query: { ... },
})
```

### account

* **Type:** `Address`

The address of the account executing the transaction.

```ts
const hash = await processConduitQuery(walletClient, {
  conduit: '0x...',
  account: '0xd2135CfB216b74109775236E36d4b433F1DF507B', // [!code focus]
  query: { ... },
})
```

### query

* **Type:** `ConduitQuery`

The query to process.

#### query.owner

* **Type:** `Address`

The owner address for the query.

#### query.receiver

* **Type:** `Address`

The receiver address for the query.

#### query.input

* **Type:** `Asset`

The input assets for the query. See [`Asset`](/types/Asset).

#### query.output

* **Type:** `Asset`

The output assets for the query. See [`Asset`](/types/Asset).

#### query.mode

* **Type:** `ConduitMode`

The conduit mode for the query. See [`Enums`](/types/Enums).

#### query.salt

* **Type:** `Hex`

The salt for the query.

#### query.data

* **Type:** `Hex`

Additional data for the query.
