Skip to content

Authorization.toRpc

Converts an Authorization.Authorization to an Authorization.Rpc.

Imports

Named
import { Authorization } from 'ox'

Examples

import { Authorization } from 'ox'
 
const authorization = Authorization.toRpc({
  address: '0x0000000000000000000000000000000000000000',
  chainId: 1,
  nonce: 1n,
  r: 44944627813007772897391531230081695102703289123332187696115181104739239197517n,
  s: 36528503505192438307355164441104001310566505351980369085208178712678799181120n,
  yParity: 0,
})

Definition

function toRpc(
  authorization: Signed,
): Rpc

Source: src/Authorization.ts

Parameters

authorization

An Authorization.

Return Type

An RPC-formatted Authorization.

Rpc