---
title: dots.v2.firewalls.get()
description: List All Firewalls
product: Reference
url: https://docs.digitalocean.com/reference/dots/reference/firewalls/firewalls-list/
last_updated: "2026-11-18"
---

> **For AI agents:** The documentation index is at [https://docs.digitalocean.com/llms.txt](https://docs.digitalocean.com/llms.txt). Markdown versions of pages use the same URL with `index.html.md` in place of the HTML page (for example, append `index.html.md` to the directory path instead of opening the HTML document).

# dots.v2.firewalls.get()

Generated on 18 Nov 2026 from DoTs version [`v1.25.0`](https://github.com/digitalocean/dots/releases/tag/v1.25.0)

## Usage

```typescript
client.v2.firewalls.get(requestConfiguration?: RequestConfiguration<FirewallsRequestBuilderGetQueryParameters>): Promise<undefined | FirewallsGetResponse>
```

## Description

To list all of the firewalls available on your account, send a GET request to [`/v2/firewalls`](https://docs.digitalocean.com/reference/api/reference/firewalls/index.html.md#firewalls_list).

## Parameters

`perPage` integer optional

Example: `2`

Number of items returned per page

Default: `20`

Min: `1`

Max: `200`

`page` integer optional

Example: `1`

Which 'page' of paginated results to return.

Default: `1`

Min: `1`

## Request Sample

## Show Request Sample

```typescript
import { FetchRequestAdapter } from "@microsoft/kiota-http-fetchlibrary";
import {
    createDigitalOceanClient,
    DigitalOceanApiKeyAuthenticationProvider,
} from "@digitalocean/dots";

const authProvider = new DigitalOceanApiKeyAuthenticationProvider(process.env.DIGITALOCEAN_TOKEN!);
const adapter = new FetchRequestAdapter(authProvider);
const client = createDigitalOceanClient(adapter);

const response = await client.v2.firewalls.get();
```

## Pagination

This method returns paginated results. The response includes a `links.pages` object with URLs for navigating between pages. To retrieve the next page, parse the `next` URL and pass the `page` query parameter:

```typescript
let response = await client.v2.firewalls.get();
let pages = response?.links?.pages;

while (pages && "next" in pages && typeof pages.next === "string") {
    const page = Number(new URL(pages.next).searchParams.get("page"));
    response = await client.v2.firewalls.get({
        queryParameters: {
            page,
        },
    });
    pages = response?.links?.pages;
}
```

## Response Example

## Show Response Example

```json
{
  "firewalls": [
    {
      "id": "fb6045f1-cf1d-4ca3-bfac-18832663025b",
      "name": "firewall",
      "status": "succeeded",
      "inbound_rules": [
        {
          "protocol": "tcp",
          "ports": "80",
          "action": "allow",
          "sources": {
            "load_balancer_uids": [
              "4de7ac8b-495b-4884-9a69-1050c6793cd6"
            ]
          }
        },
        {
          "protocol": "tcp",
          "ports": "22",
          "action": "allow",
          "sources": {
            "tags": [
              "gateway"
            ],
            "addresses": [
              "18.0.0.0/8"
            ]
          }
        }
      ],
      "outbound_rules": [
        {
          "protocol": "tcp",
          "ports": "80",
          "action": "allow",
          "destinations": {
            "addresses": [
              "0.0.0.0/0",
              "::/0"
            ]
          }
        }
      ],
      "created_at": "2017-05-23T21:23:59Z",
      "droplet_ids": [
        8043964
      ],
      "tags": [],
      "pending_changes": []
    }
  ],
  "links": {},
  "meta": {
    "total": 1
  }
}
```

## More Information

See [`/v2/firewalls`](https://docs.digitalocean.com/reference/api/reference/firewalls/index.html.md#firewalls_list) in the API reference for additional detail on responses, headers, parameters, and more.