---
title: "api request"
description: "Make a raw API request"
canonical: "https://pgbeam.com/docs/cli/api/request"
last-updated: "2026-09-14T19:37:21.000Z"
---

# api request

> Make a raw API request

URL: https://pgbeam.com/docs/cli/api/request

Make a direct HTTP request to the PgBeam API. Supports path parameter interpolation: if the path matches a known API route template, path parameters are extracted automatically. Use `--data` (or `-d`) to send a JSON request body. Every request is authenticated via the active profile (or `--token` / `PGBEAM_API_KEY`), including reads like `/v1/regions`.

## Usage

## Options

Option

Description

Required

Default

`<method>`

HTTP method: GET, POST, PATCH, PUT, or DELETE

Yes

-

`<path>`

API path (e.g. /v1/projects, /v1/regions)

Yes

-

`--data <value>`, `-d`

JSON request body to send with the request

No

-

All global options (`--token`, `--profile`,
`--project`, `--org`, `--json`, `--no-color`, `--no-trunc`, `--debug`) are
also available on this command.

## Examples

## Output

Outputs the API response as formatted JSON. Exits with a non-zero code on HTTP errors.