# setOperatorApproval

```ts
function setOperatorApproval(client, options): Promise<`0x${string}`>;
```

Defined in: [packages/synapse-core/src/pay/operators.ts:96](https://github.com/FilOzone/synapse-sdk/blob/1d6c4b9fe34534bf1087dfe41491b72be0b46858/packages/synapse-core/src/pay/operators.ts#L96)

Set the operator approval for the payments contract.

## Parameters

| Parameter | Type | Description |
| ------ | ------ | ------ |
| `client` | `Client`\<`Transport`, `Chain`, `Account`\> | The client to use. |
| `options` | [`SetOperatorApprovalOptions`](/reference/filoz/synapse-core/pay/type-aliases/setoperatorapprovaloptions/) | The options to use. |

## Returns

[`Promise`](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)\<`` `0x${string}` ``\>

The hash of the approve transaction.

## Throws

- SimulateContractErrorType if the simulate contract fails.

## Throws

- WriteContractErrorType if the write contract fails.