# Abi.format

Formats an [`Abi.Abi`](/api/Abi/types#abi) into a **Human Readable ABI**.

## Imports

:::code-group
```ts [Named]
import { Abi } from 'ox'
```

```ts [Entrypoint]
import * as Abi from 'ox/Abi'
```
:::

## Examples

```ts twoslash
import { Abi } from 'ox'

const formatted = Abi.format([
  {
    type: 'function',
    name: 'approve',
    stateMutability: 'nonpayable',
    inputs: [
      {
        name: 'spender',
        type: 'address'
      },
      {
        name: 'amount',
        type: 'uint256'
      }
    ],
    outputs: [{ type: 'bool' }]
  }
])

formatted
//    ^?
```

## Definition

```ts
function format(
  abi: Abi | readonly unknown[],
): readonly string[]
```

**Source:** [src/core/Abi.ts](https://github.com/wevm/ox/blob/main/src/core/Abi.ts#L136)

## Parameters

### abi

* **Type:** `Abi | readonly unknown[]`

The ABI to format.

## Return Type

The formatted ABI.

`readonly string[]`
