CarmenCloudClient
Class A client for the Carmen Cloud API: workspaces, members, API keys, billing, usage, stored events, storage settings and hooks.
const client = new CarmenCloudClient({ apiKey: process.env.CARMEN_API_KEY });
const workspace = await client.workspace.get();
const keys = await client.apiKeys.list({ limit: 50 });
Properties
| Name | Type | Description |
|---|---|---|
readonly apiKeys | ApiKeyOperations | - |
readonly auth? | AuthClient | The token exchange client (only when an apiKey is configured). |
baseUrl | string | - |
readonly billing | BillingOperations | - |
readonly events | EventOperations | - |
readonly hooks | HookOperations | - |
http | AxiosInstance | - |
readonly members | MemberOperations | - |
options | CarmenCloudClientOptions | - |
readonly storage | StorageOperations | - |
readonly usage | UsageOperations | - |
readonly workspace | WorkspaceOperations | - |
Members
constructor
(options: CarmenCloudClientOptions) => CarmenCloudClient
Parameters
| Name | Type | Description |
|---|---|---|
options | CarmenCloudClientOptions | - |
bearer
(forceRefresh: boolean) => Promise
Parameters
| Name | Type | Description |
|---|---|---|
forceRefresh | boolean | - |
getWorkspaceId
() => Promise
The workspace the client operates on.
request
(method: string, path: string, options: RequestOptions) => Promise
Parameters
| Name | Type | Description |
|---|---|---|
method | string | - |
path | string | - |
options | RequestOptions | - |
Source: carmen-cloud/index.ts:83