Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ integration guides live under `integrations/`.

| Surface | Modules | Description |
| ------------------------ | -------------------------: | ------------------------------------------------------------------------------------------------ |
| [`API`](./api/_index.md) | 9 modules · 101 endpoints | Project-scoped data operations: database collections, users, AI chat, auth, API keys. |
| [`Hub`](./hub/_index.md) | 27 modules · 538 endpoints | Project & account configuration: schemas, integrations, team management, billing, observability. |
| [`API`](./api/_index.md) | 10 modules · 112 endpoints | Project-scoped data operations: database collections, users, AI chat, auth, API keys. |
| [`Hub`](./hub/_index.md) | 27 modules · 575 endpoints | Project & account configuration: schemas, integrations, team management, billing, observability. |

## Integration guides

Expand Down
25 changes: 13 additions & 12 deletions docs/api/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,18 @@

Project-scoped data operations: database collections, users, AI chat, auth, API keys.

**101 endpoints across 9 modules.** Click a module
**112 endpoints across 10 modules.** Click a module
name for the full method reference and TypeScript examples.

| Module | Endpoints | Description |
| ---------------------------------- | --------: | ---------------------------------------------------------------------------------------------------------------------------------------- |
| [`accessToken`](./access_token.md) | 1 | Refresh-token exchange to get a new bearer token. |
| [`ai`](./ai.md) | 18 | |
| [`apikeys`](./apikeys.md) | 2 | List and regenerate per-environment API keys for service auth. |
| [`auth`](./auth.md) | 1 | Sign-in / sign-out and federated provider flows. Most apps prefer `norbix.login(...)` over calling these directly. |
| [`database`](./database.md) | 22 | Database schemas, integrations, triggers, taxonomies, and module on/off switches. For data-level CRUD on collections see `api.database`. |
| [`echo`](./echo.md) | 1 | Echo helpers used by the gateway smoke checks. |
| [`files`](./files.md) | 13 | File storage integrations and triggers. Upload + download is in `api.database` (FileResource fields). |
| [`membership`](./membership.md) | 42 | Roles, policies, and user preferences (Hub side). For user CRUD and registration see `api.membership`. |
| [`public`](./public.md) | 2 | |
| Module | Endpoints | Description |
| ------------------------------------- | --------: | ---------------------------------------------------------------------------------------------------------------------------------------- |
| [`accessToken`](./access_token.md) | 1 | Refresh-token exchange to get a new bearer token. |
| [`ai`](./ai.md) | 18 | |
| [`apikeys`](./apikeys.md) | 2 | List and regenerate per-environment API keys for service auth. |
| [`auth`](./auth.md) | 1 | Sign-in / sign-out and federated provider flows. Most apps prefer `norbix.login(...)` over calling these directly. |
| [`database`](./database.md) | 22 | Database schemas, integrations, triggers, taxonomies, and module on/off switches. For data-level CRUD on collections see `api.database`. |
| [`echo`](./echo.md) | 1 | Echo helpers used by the gateway smoke checks. |
| [`files`](./files.md) | 14 | File storage integrations and triggers. Upload + download is in `api.database` (FileResource fields). |
| [`membership`](./membership.md) | 43 | Roles, policies, and user preferences (Hub side). For user CRUD and registration see `api.membership`. |
| [`notifications`](./notifications.md) | 7 | Email and push templates, integrations, campaigns, devices, signatures, footers, and one-click unsubscribe. |
| [`public`](./public.md) | 3 | |
4 changes: 4 additions & 0 deletions docs/api/apikeys.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ Accessed as `norbix.api.apikeys` on the [`Norbix`](../../README.md#authenticatio

Fetch a single item by ID.

> **Deprecated.** The gateway has no `/apikeys` endpoint, so this call fails. Use service-user API keys (`norbix.hub.membership.listServiceUserApiKeys`).

**Request DTO**: `CodeMashApi2.GetApiKeys`
**Response**: `CodeMashApi2.GetApiKeysResponse`

Expand All @@ -41,6 +43,8 @@ const result = await norbix.api.apikeys.getApiKeys({

`POST` `/apikeys/regenerate`

> **Deprecated.** The gateway has no `/apikeys/regenerate` endpoint, so this call fails. Use `norbix.hub.membership.issueServiceUserApiKey`.

**Request DTO**: `CodeMashApi2.RegenerateApiKeys`
**Response**: `CodeMashApi2.RegenerateApiKeysResponse`

Expand Down
10 changes: 5 additions & 5 deletions docs/api/database.md
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ const result = await norbix.api.database.executeAggregate({

`GET` `/{version}/database/collections/{collectionName}`

Search / paginate items. Takes `expandReferences: true` to read every reference field as `{ id, display }` — see [Reading references](../database-rules.md#reading-references--expandreferences).
Search / paginate items.

**Request DTO**: `CodeMashApi2.FindRequest`
**Response**: `CodeMashApi2.FindResponse`
Expand All @@ -382,7 +382,7 @@ const result = await norbix.api.database.find({

`GET` `/{version}/database/collections/{collectionName}/{id}`

Fetch one record by id. Takes `expandReferences: true` to read every reference field as `{ id, display }` — see [Reading references](../database-rules.md#reading-references--expandreferences).
Search / paginate items.

**Request DTO**: `CodeMashApi2.FindOneRequest`
**Response**: `CodeMashApi2.FindOneResponse`
Expand All @@ -406,7 +406,7 @@ const result = await norbix.api.database.findOne({

`GET` `/{version}/database/collections/{collectionName}/own`

Search / paginate items. Takes `expandReferences: true` to read every reference field as `{ id, display }` — see [Reading references](../database-rules.md#reading-references--expandreferences).
Search / paginate items.

**Request DTO**: `CodeMashApi2.FindOwnRequest`
**Response**: `CodeMashApi2.FindResponse`
Expand Down Expand Up @@ -499,7 +499,7 @@ const result = await norbix.api.database.replaceOne({

`PUT` `/{version}/database/collections/{collectionName}/many`

Update an existing item. Keys may be nested paths; `arrayFilters` picks the list elements a `$[name]` path changes — see [Nested documents and arrays](../database-rules.md#nested-documents-and-arrays).
Update an existing item.

**Request DTO**: `CodeMashApi2.UpdateManyRequest`
**Response**: `CodeMashApi2.EmptyResponse`
Expand All @@ -522,7 +522,7 @@ const result = await norbix.api.database.updateMany({

`PUT` `/{version}/database/collections/{collectionName}/{id}`

Update an existing item. Keys may be nested paths; `arrayFilters` picks the list elements a `$[name]` path changes — see [Nested documents and arrays](../database-rules.md#nested-documents-and-arrays).
Update an existing item.

**Request DTO**: `CodeMashApi2.UpdateOneRequest`
**Response**: `CodeMashApi2.EmptyResponse`
Expand Down
25 changes: 24 additions & 1 deletion docs/api/files.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ Accessed as `norbix.api.files` on the [`Norbix`](../../README.md#authentication)
| [`getPublicFile`](#getpublicfile) | `GET` | `/{version}/files/public/{PublicId}/{Name*}` | `project` |
| [`requestUploadUrl`](#requestuploadurl) | `POST` | `/{version}/files/{filesIntegrationId}/upload-url` | `project` |
| [`testFilesIntegration`](#testfilesintegration) | `POST` | `/{version}/files/{filesIntegrationId}/test` | `project` |
| [`useFile`](#usefile) | `POST` | `/{version}/files/{filesIntegrationId}/use` | `project` |

## Reference

Expand Down Expand Up @@ -162,7 +163,7 @@ const result = await norbix.api.files.downloadFileApi({

`GET` `/{version}/files/{filesIntegrationId}/by-id/{id}`

Fetch one file by its stable id — the id a file field on a record stores, and the `id` an expanded reference (`expandReferences: true`) returns. The answer carries the file's `resource`, `path`, `isPublic` and `publicUrl`. An id no storage of the integration holds answers not found.
Fetch a single item by ID.

**Request DTO**: `CodeMashApi2.GetFileByIdRequest`
**Response**: `CodeMashApi2.GetFileByIdResponse`
Expand All @@ -175,6 +176,7 @@ const norbix = new Norbix();
const result = await norbix.api.files.getFileById({
filesIntegrationId: 'filesIntegrationId-here',
id: 'id-here',
// Other fields: see CodeMash type for the full request shape.
});
// → typed as CodeMashApi2.GetFileByIdResponse
```
Expand Down Expand Up @@ -315,3 +317,24 @@ const result = await norbix.api.files.testFilesIntegration({
```

[↑ Top](#endpoints)

### useFile

`POST` `/{version}/files/{filesIntegrationId}/use`

**Request DTO**: `CodeMashApi2.UseFileRequest`
**Response**: `CodeMashApi2.IdResponse`

```ts
import { Norbix } from '@norbix.ai/ts';

const norbix = new Norbix();

const result = await norbix.api.files.useFile({
filesIntegrationId: 'filesIntegrationId-here',
// Other fields: see CodeMash type for the full request shape.
});
// → typed as CodeMashApi2.IdResponse
```

[↑ Top](#endpoints)
47 changes: 34 additions & 13 deletions docs/api/membership.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ Accessed as `norbix.api.membership` on the [`Norbix`](../../README.md#authentica
| [`blockUser`](#blockuser) | `PATCH` | `/{version}/membership/auth/block` | `project` |
| [`saveSystemUserWithPermissions`](#savesystemuserwithpermissions) | `POST` | `/{version}/membership/auth/register/service` | `project` |
| [`saveGuestUser`](#saveguestuser) | `POST` | `/{version}/membership/auth/register/guest` | `project` |
| [`savePhoneUser`](#savephoneuser) | `POST` | `/{version}/membership/auth/register/phone` | `project` |
| [`saveUserNameUser`](#saveusernameuser) | `POST` | `/{version}/membership/auth/register/user-name` | `project` |
| [`saveEmailUser`](#saveemailuser) | `POST` | `/{version}/membership/auth/register/email` | `project` |
| [`savePhoneUser`](#savephoneuser) | `POST` | `/{version}/membership/auth/register/phone` | `project` |
| [`savePhoneUserNameWithPermissions`](#savephoneusernamewithpermissions) | `POST` | `/{version}/membership/auth/register/phone-with-permissions` | `project` |
| [`saveEmailUserNameWithPermissions`](#saveemailusernamewithpermissions) | `POST` | `/{version}/membership/auth/register/email-with-permissions` | `project` |
| [`saveUserNameWithPermissions`](#saveusernamewithpermissions) | `POST` | `/{version}/membership/auth/register/user-name-with-permissions` | `project` |
Expand All @@ -25,6 +25,7 @@ Accessed as `norbix.api.membership` on the [`Norbix`](../../README.md#authentica
| [`getUserPreferences`](#getuserpreferences) | `GET` | `/{version}/membership/auth/{id}/preferences` | `project` |
| [`grantContactConsent`](#grantcontactconsent) | `POST` | `/{version}/membership/users/{contactId}/marketing-state/{channel}/consent` | `project` |
| [`inviteUser`](#inviteuser) | `POST` | `/{version}/membership/auth/invite` | `project` |
| [`finishInvitation`](#finishinvitation) | `POST` | `/{version}/membership/auth/invitation/finish` | `project` |
| [`linkIdentity`](#linkidentity) | `POST` | `/{version}/membership/auth/{userId}/link-identity` | `project` |
| [`mapAuthToUser`](#mapauthtouser) | `POST` | `/{version}/membership/users/{userId}/map-auth` | `project` |
| [`assignRolePermissions`](#assignrolepermissions) | `PUT` | `/{version}/membership/auth/assign-roles` | `project` |
Expand Down Expand Up @@ -121,65 +122,65 @@ const result = await norbix.api.membership.saveGuestUser({

[↑ Top](#endpoints)

### saveUserNameUser
### savePhoneUser

`POST` `/{version}/membership/auth/register/user-name`
`POST` `/{version}/membership/auth/register/phone`

Upsert an item (create or update).

**Request DTO**: `CodeMashApi2.SaveUserNameUser`
**Request DTO**: `CodeMashApi2.SavePhoneUser`
**Response**: `CodeMashApi2.IdResponse`

```ts
import { Norbix } from '@norbix.ai/ts';

const norbix = new Norbix();

const result = await norbix.api.membership.saveUserNameUser({
const result = await norbix.api.membership.savePhoneUser({
// See CodeMash type for the full request shape.
});
// → typed as CodeMashApi2.IdResponse
```

[↑ Top](#endpoints)

### saveEmailUser
### saveUserNameUser

`POST` `/{version}/membership/auth/register/email`
`POST` `/{version}/membership/auth/register/user-name`

Upsert an item (create or update).

**Request DTO**: `CodeMashApi2.SaveEmailUser`
**Request DTO**: `CodeMashApi2.SaveUserNameUser`
**Response**: `CodeMashApi2.IdResponse`

```ts
import { Norbix } from '@norbix.ai/ts';

const norbix = new Norbix();

const result = await norbix.api.membership.saveEmailUser({
const result = await norbix.api.membership.saveUserNameUser({
// See CodeMash type for the full request shape.
});
// → typed as CodeMashApi2.IdResponse
```

[↑ Top](#endpoints)

### savePhoneUser
### saveEmailUser

`POST` `/{version}/membership/auth/register/phone`
`POST` `/{version}/membership/auth/register/email`

Upsert an item (create or update).

**Request DTO**: `CodeMashApi2.SavePhoneUser`
**Request DTO**: `CodeMashApi2.SaveEmailUser`
**Response**: `CodeMashApi2.IdResponse`

```ts
import { Norbix } from '@norbix.ai/ts';

const norbix = new Norbix();

const result = await norbix.api.membership.savePhoneUser({
const result = await norbix.api.membership.saveEmailUser({
// See CodeMash type for the full request shape.
});
// → typed as CodeMashApi2.IdResponse
Expand Down Expand Up @@ -385,6 +386,26 @@ const result = await norbix.api.membership.inviteUser({

[↑ Top](#endpoints)

### finishInvitation

`POST` `/{version}/membership/auth/invitation/finish`

**Request DTO**: `CodeMashApi2.FinishInvitationRequest`
**Response**: `CodeMashApi2.EmptyResponse`

```ts
import { Norbix } from '@norbix.ai/ts';

const norbix = new Norbix();

const result = await norbix.api.membership.finishInvitation({
// See CodeMash type for the full request shape.
});
// → typed as CodeMashApi2.EmptyResponse
```

[↑ Top](#endpoints)

### linkIdentity

`POST` `/{version}/membership/auth/{userId}/link-identity`
Expand Down
Loading
Loading