> For the complete documentation index, see [llms.txt](https://codemash.gitbook.io/codemash/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://codemash.gitbook.io/codemash/cli/reference/any-endpoint.md).

# Any endpoint

Call any Hub or API endpoint with plain words or a raw path, and read the CLI as data.

Call any Hub or API endpoint with plain words or a raw path, and read the CLI as data.

4 commands (`@norbix.ai/cli` 1.16.0):

* [`norbix api`](#norbix-api) — Call any data-plane API endpoint with plain words.
* [`norbix hub`](#norbix-hub) — Call any Hub endpoint with plain words.
* [`norbix raw`](#norbix-raw) — Low-level escape hatch: call a raw HTTP path on the hub (default) or API.
* [`norbix schema`](#norbix-schema) — Describe the CLI as data: every command with its args, flags, examples, whether it is destructive and whether it supports --dry-run.

## `norbix api`

Call any data-plane API endpoint with plain words.

```
Grammar: norbix api <module> <words...> [id] [--field value | --body '<json>']
Same engine as `norbix hub` — see `norbix hub --help`. For raw HTTP paths
use `norbix raw`.
```

```sh
norbix api [flags]
```

| Flag               | Description                                                                               |
| ------------------ | ----------------------------------------------------------------------------------------- |
| `-y`, `--yes`      | Skip the confirmation prompt (required in non-interactive shells)                         |
| `--dry-run`        | Resolve context and print the request that would be sent; send nothing                    |
| `--body` `<value>` | The whole request as a JSON object (or `-` for stdin); cannot be mixed with --field flags |

Also takes the [global flags](/codemash/cli/reference.md#global-flags): `--json`, `--project`, `--env`, `--region`, `--api-key`, `--account`, `--profile`.

Examples:

```sh
norbix api                          # list modules
norbix api database                 # list database methods
norbix api database find --collectionName orders --pageSize 20
norbix api membership users get
norbix api membership user delete 66b2f0a1c3d4e5f6a7b8c9d0 --dry-run
norbix api membership user delete 66b2f0a1c3d4e5f6a7b8c9d0 --yes --json
norbix api database insert --body '{"collectionName":"orders","document":"{\"status\":\"new\"}"}'
```

## `norbix hub`

Call any Hub endpoint with plain words.

```
Grammar: norbix hub <module> <words...> [id] [--field value | --body '<json>']
The method is resolved from the words — plural means "list", singular (or a
positional id) means one item. Destructive verbs (delete, remove, stop,
disable, block, regenerate, rotate) ask for confirmation; without a terminal
they exit 3 unless --yes. Add --dry-run to see the exact request first.
Field values are typed from the SDK's request type; force one with
--field:str / :num / :bool / :json, or pass the whole request with --body.
`norbix hub <module> --help` lists every method with its fields.
```

```sh
norbix hub [flags]
```

| Flag               | Description                                                                               |
| ------------------ | ----------------------------------------------------------------------------------------- |
| `-y`, `--yes`      | Skip the confirmation prompt (required in non-interactive shells)                         |
| `--dry-run`        | Resolve context and print the request that would be sent; send nothing                    |
| `--body` `<value>` | The whole request as a JSON object (or `-` for stdin); cannot be mixed with --field flags |

Also takes the [global flags](/codemash/cli/reference.md#global-flags): `--json`, `--project`, `--env`, `--region`, `--api-key`, `--account`, `--profile`.

Examples:

```sh
norbix hub                              # list modules
norbix hub database                     # list database methods
norbix hub database aggregates get
norbix hub database aggregates delete maggr_123 --schemaId sch_456
norbix hub scheduler tasks get --pageSize 100
norbix hub logs get --level Error
norbix hub scheduler task delete 66b2f0a1c3d4e5f6a7b8c9d0 --dry-run
norbix hub scheduler task delete 66b2f0a1c3d4e5f6a7b8c9d0 --yes --json
norbix hub scheduler task save --body '{"name":"nightly","cronExpression":"0 2 * * *"}'
norbix hub membership user get --userId:str 0042
```

## `norbix raw`

Low-level escape hatch: call a raw HTTP path on the hub (default) or API.

```
Prefer `norbix hub ...` / `norbix api ...` — they take plain words.
Use this only for endpoints the SDK does not know yet. Sends your auth token
plus project/account/env/region headers automatically. Use {version} in the
path and it becomes v2.
```

```sh
norbix raw PATH [flags]
```

| Argument | Required | Description                                     |
| -------- | -------- | ----------------------------------------------- |
| `PATH`   | yes      | Endpoint path, e.g. /v2/logs or /{version}/logs |

| Flag                       | Description                                                                   |
| -------------------------- | ----------------------------------------------------------------------------- |
| `--dry-run`                | Resolve context and print the request that would be sent; send nothing        |
| `--api`                    | Call the data-plane API service instead of the hub (hub is the default)       |
| `-X`, `--method` `<value>` | HTTP method — one of: `GET`, `POST`, `PUT`, `PATCH`, `DELETE`; default: `GET` |
| `-b`, `--body` `<value>`   | JSON request body (or `-` for stdin)                                          |
| `-q`, `--query` `<value>`  | Query parameter key=value (repeatable) — repeat for several                   |

Also takes the [global flags](/codemash/cli/reference.md#global-flags): `--json`, `--project`, `--env`, `--region`, `--api-key`, `--account`, `--profile`.

Examples:

```sh
norbix raw /v2/logs/settings
norbix raw '/{version}/database/collections/orders/count' --api --query filter='{"status":"paid"}'
norbix raw /v2/scheduler/tasks --method POST --body '{"name":"nightly","cronExpression":"0 2 * * *"}' --dry-run
```

## `norbix schema`

Describe the CLI as data: every command with its args, flags, examples, whether it is destructive and whether it supports --dry-run.

```
Made for coding agents and scripts: run it once with --json, then
`norbix <command> --help` for details. The plain-word `hub` / `api`
commands are dynamic — their methods and request fields come from
`norbix hub <module> --json`.
```

```sh
norbix schema [COMMAND]
```

| Argument  | Required | Description                                                                 |
| --------- | -------- | --------------------------------------------------------------------------- |
| `COMMAND` | no       | A command ("users delete") or topic ("db") to describe; omit for everything |

Also takes the [global flags](/codemash/cli/reference.md#global-flags): `--json`, `--project`, `--env`, `--region`, `--api-key`, `--account`, `--profile`.

Examples:

```sh
norbix schema
norbix schema --json
norbix schema users delete --json
norbix schema db --json
```
