@flashbacktech/tsclient 0.4.37 → 0.4.40

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -143,12 +143,27 @@ interface SimpleResponse$2 {
143
143
  message?: string;
144
144
  error_code?: string;
145
145
  }
146
+ /**
147
+ * Unauthenticated config the SPA reads at boot (GET /public-config) to decide
148
+ * what to render before any session exists — e.g. whether self-service signup
149
+ * is available. Reflects the backend's OPEN_REGISTRATION at runtime.
150
+ */
151
+ interface PublicConfig {
152
+ openRegistration: boolean;
153
+ appName?: string;
154
+ }
146
155
 
147
156
  declare class AuthClient {
148
157
  private readonly http;
149
158
  constructor(http: BaseClient);
150
159
  login(body: LoginRequest): Promise<SessionResponse>;
151
160
  register(body: RegisterRequest): Promise<SessionResponse>;
161
+ /**
162
+ * Unauthenticated boot config. The SPA reads `openRegistration` to decide
163
+ * whether to render the self-service signup form (false => invite-only /
164
+ * preview mode). Safe to call before any session exists.
165
+ */
166
+ publicConfig(): Promise<PublicConfig>;
152
167
  logout(refreshToken?: string): Promise<SimpleResponse$2>;
153
168
  refresh(body: RefreshRequest): Promise<SessionResponse>;
154
169
  activate(body: ActivateRequest): Promise<SessionResponse>;
@@ -320,6 +335,31 @@ interface AcceptInviteRequest {
320
335
  token: string;
321
336
  password: string;
322
337
  }
338
+ /**
339
+ * Platform-admin payload for provisioning a brand-new organization and its
340
+ * founding owner in invite-only / preview mode (POST /organization/invite-org).
341
+ * The backend creates the org + owner (role=Owner, no password), provisions a
342
+ * subscription, and emails the owner an invite link. The owner finishes
343
+ * onboarding by accepting the invite (sets a password) or signing in via SSO.
344
+ */
345
+ interface InviteOrgRequest {
346
+ orgName: string;
347
+ website?: string;
348
+ isBusiness?: boolean;
349
+ owner: {
350
+ email: string;
351
+ firstName: string;
352
+ lastName?: string;
353
+ };
354
+ /** Override the configured free tier with a specific plan name. */
355
+ subscriptionName?: string;
356
+ /** Comped credit grant in USD micros; overrides the plan's default grant. */
357
+ creditsMicros?: number;
358
+ }
359
+ interface InviteOrgResult {
360
+ organization: Organization;
361
+ owner: OrganizationUser;
362
+ }
323
363
  interface SimpleOrgResponse {
324
364
  success: boolean;
325
365
  message?: string;
@@ -350,6 +390,14 @@ declare class OrganizationClient {
350
390
  name: string;
351
391
  allowDebug: boolean;
352
392
  }>>;
393
+ /**
394
+ * Platform-admin only: provision a new organization + founding owner and
395
+ * email the owner an invite link. The invite-only counterpart to public
396
+ * self-service registration (used while the backend has OPEN_REGISTRATION
397
+ * disabled). Returns 403 unless the caller's home org is the configured
398
+ * ADMIN_ORGANIZATION; 409 when the owner email already exists.
399
+ */
400
+ inviteOrg(body: InviteOrgRequest): Promise<InviteOrgResult>;
353
401
  /**
354
402
  * Platform-admin only: enable or disable the debug surface for an org.
355
403
  * Returns the updated org entry with the new allowDebug value.
@@ -468,7 +516,7 @@ interface UpdateCredentialRequest {
468
516
  interface ListCredentialsQuery {
469
517
  projectId: string;
470
518
  provider?: ProviderID;
471
- capability?: 'storage' | 'ai' | 'compute' | 'vcs';
519
+ capability?: 'storage' | 'ai' | 'compute' | 'vcs' | 'notify';
472
520
  }
473
521
  interface SandboxCredential {
474
522
  sandboxId: string;
@@ -528,6 +576,7 @@ declare const CAP_STORAGE = 1;
528
576
  declare const CAP_AI = 2;
529
577
  declare const CAP_COMPUTE = 4;
530
578
  declare const CAP_VCS = 8;
579
+ declare const CAP_NOTIFY = 16;
531
580
  declare const CAP_GENERAL = 255;
532
581
  interface ProviderSpec {
533
582
  id: string;
@@ -2023,4 +2072,4 @@ declare class NotImplementedError extends Error {
2023
2072
  constructor(method: string);
2024
2073
  }
2025
2074
 
2026
- export { type AcceptInviteRequest, AccessType, type AcquireScanLeaseRequest, type AcquireScanLeaseResponse, type ActionCategory, type ActivateRequest, type AddMemberRequest, type AnswerChatQuestionRequest, type AnswerChatQuestionResponse, type AuthUser, BaseClient, type BaseClientOptions, type BudgetScope, BudgetsClient, type BuyCustomCreditRequest, type BuyCustomCreditResponse, type BuySubscriptionRequest, type BuySubscriptionResponse, CAP_AI, CAP_COMPUTE, CAP_GENERAL, CAP_STORAGE, CAP_VCS, type CancelChatTurnResponse, type CancelSubscriptionResponse, type ChatAssistantMessagePayload, type ChatBillingRefuseCode, type ChatBillingRefuseError, type ChatBudget, type ChatCheckpointedPayload, type ChatCompactionFiredPayload, type ChatDonePayload, type ChatEvent, type ChatEventType, type ChatMessage, type ChatMessageKind, type ChatMessageRole, type ChatNarrationPayload, type ChatPhase, type ChatPhasePayload, type ChatPlanDraftPayload, type ChatQuestionPayload, type ChatSchedule, type ChatScheduleEnvelope, type ChatScheduleRunStatus, type ChatScope, type ChatSession, type ChatSessionSource, type ChatSessionTitlePayload, type ChatStepEventPayload, type ChatStepProgressPayload, type ChatStreamHandle, type ChatToolCallConfirmationRequiredPayload, type ChatToolCallFinishedPayload, type ChatToolCallStartedPayload, type ClarificationOption, CloudAgentClient, type CloudAgentClientOptions, type CloudResource, type CloudResourceContainerRef, type CloudResourceEdge, type CloudScanHistory, type CloudScanLease, type ConfirmChatToolCallRequest, type ConfirmChatToolCallResponse, type CreateAgentTemplateRequest, type CreateChatScheduleRequest, type CreateChatSessionRequest, type CreateChatSessionResponse, type CreateCredentialRequest, type CreateGatewayTokenRequest, type CreateGatewayTokenResponse, type CreateOrganizationUserRequest, type CreateProjectRequest, type CreateSandboxRequest, type CreateScheduledTaskRequest, type Credential, type CreditBalance, type CreditTransaction, type CreditTransactionKind, type CreditTransactionType, type CustomCreditPurchaseConfig, type DebugPayload, type DebugReceipt, type EffectiveChatBudget, type ExchangeCodeRequest, type FieldSpec, type FieldType, type FineTuneParams, type GatewayToken, type GetChatSessionResponse, type GetUsageSummaryQuery, type GetUsageSummaryResponse, HttpError, type ImpersonationProvider, type ListAgentTemplatesQuery, type ListAgentTemplatesResponse, type ListChatScheduleRunsResponse, type ListChatSchedulesResponse, type ListChatSessionsQuery, type ListChatSessionsResponse, type ListCredentialsQuery, type ListCreditsTransactionsQuery, type ListCreditsTransactionsResponse, type ListPaymentsResponse, type ListSandboxesQuery, type ListScanHistoryQuery, type ListScanHistoryResponse, type ListScheduledTasksQuery, type ListScheduledTasksResponse, type LoginRequest, type MFASetupResponse, type MFASimpleResponse, type MFAStatus, MFAType, type MFAVerifyLoginRequest, type MFAVerifyLoginResponse, type MFAVerifySetupRequest, type MagicLinkActivateRequest, type MagicLinkSendResponse, type ModeType, type MonthlyCreditStats, NotImplementedError, type OpenChatStreamOptions, type OrgBudget, OrgRoles, type OrgSubscription, type Organization, type OrganizationUser, PROVIDER_CATALOG, type Payment, type PeekScanLeaseResponse, type PostChatMessageRequest, type PostChatMessageResponse, type Project, type ProjectMember, type ProviderID, type ProviderSpec, ProviderType, type Query, type ReconcileScope, type ReconcileTuple, type RefreshRequest, type RegisterRequest, type RequestOptions, type ResetPasswordRequest, type ResourceTreeCategory, type ResourceTreeCredential, type ResourceTreeGrouping, type ResourceTreeResource, type ResourceTreeResponse, ResourcesClient, type Sandbox, type SandboxCredential, type ScanInProgressError, type ScheduledTask, type ScopedBudget, type SessionResponse, type SessionTokens, type SimpleAgentResponse, type SimpleKeysResponse, type SimpleOrgResponse, type SimpleResponse$2 as SimpleResponse, type StorageType, type SubgraphDirection, type SubgraphRequest, type SubgraphResponse, type Subscription, type SubscriptionCapability, type SubscriptionPeriod, type SystemEvent, type SystemEventQuery, type SystemEventQueryResponse, type SystemEventReadResponse, type Template, type TokenProvider, type UnauthorizedHandler, type UpdateChatBudgetRequest, type UpdateChatScheduleRequest, type UpdateCostLimitRequest, type UpdateCredentialRequest, type UpdateMemberRoleRequest, type UpdateOrgBudgetRequest, type UpdateOrgUserRequest, type UpdateOrganizationRequest, type UpdateProjectRequest, type UpdateSandboxRequest, type UpdateScopedBudgetRequest, type UpdateUserRequest, type UpdateUserResponse, type UsageBucket, type UsageByModelQuery, type UsageByModelResponse, type UsageByModelRow, type UsageReportQuery, type UsageReportResponse, type UsageSummary, type UsageSummaryQuery, type UsageSummaryResponse, type UsageTotals, type UsageWindow, type UserProfile, type UserSummary, computeDisplayHint, getProvider, getValueAt, isMetadataPath, isSecretPath, listProviders, metadataKey, setValueAt, usdMicros, validate };
2075
+ export { type AcceptInviteRequest, AccessType, type AcquireScanLeaseRequest, type AcquireScanLeaseResponse, type ActionCategory, type ActivateRequest, type AddMemberRequest, type AnswerChatQuestionRequest, type AnswerChatQuestionResponse, type AuthUser, BaseClient, type BaseClientOptions, type BudgetScope, BudgetsClient, type BuyCustomCreditRequest, type BuyCustomCreditResponse, type BuySubscriptionRequest, type BuySubscriptionResponse, CAP_AI, CAP_COMPUTE, CAP_GENERAL, CAP_NOTIFY, CAP_STORAGE, CAP_VCS, type CancelChatTurnResponse, type CancelSubscriptionResponse, type ChatAssistantMessagePayload, type ChatBillingRefuseCode, type ChatBillingRefuseError, type ChatBudget, type ChatCheckpointedPayload, type ChatCompactionFiredPayload, type ChatDonePayload, type ChatEvent, type ChatEventType, type ChatMessage, type ChatMessageKind, type ChatMessageRole, type ChatNarrationPayload, type ChatPhase, type ChatPhasePayload, type ChatPlanDraftPayload, type ChatQuestionPayload, type ChatSchedule, type ChatScheduleEnvelope, type ChatScheduleRunStatus, type ChatScope, type ChatSession, type ChatSessionSource, type ChatSessionTitlePayload, type ChatStepEventPayload, type ChatStepProgressPayload, type ChatStreamHandle, type ChatToolCallConfirmationRequiredPayload, type ChatToolCallFinishedPayload, type ChatToolCallStartedPayload, type ClarificationOption, CloudAgentClient, type CloudAgentClientOptions, type CloudResource, type CloudResourceContainerRef, type CloudResourceEdge, type CloudScanHistory, type CloudScanLease, type ConfirmChatToolCallRequest, type ConfirmChatToolCallResponse, type CreateAgentTemplateRequest, type CreateChatScheduleRequest, type CreateChatSessionRequest, type CreateChatSessionResponse, type CreateCredentialRequest, type CreateGatewayTokenRequest, type CreateGatewayTokenResponse, type CreateOrganizationUserRequest, type CreateProjectRequest, type CreateSandboxRequest, type CreateScheduledTaskRequest, type Credential, type CreditBalance, type CreditTransaction, type CreditTransactionKind, type CreditTransactionType, type CustomCreditPurchaseConfig, type DebugPayload, type DebugReceipt, type EffectiveChatBudget, type ExchangeCodeRequest, type FieldSpec, type FieldType, type FineTuneParams, type GatewayToken, type GetChatSessionResponse, type GetUsageSummaryQuery, type GetUsageSummaryResponse, HttpError, type ImpersonationProvider, type InviteOrgRequest, type InviteOrgResult, type ListAgentTemplatesQuery, type ListAgentTemplatesResponse, type ListChatScheduleRunsResponse, type ListChatSchedulesResponse, type ListChatSessionsQuery, type ListChatSessionsResponse, type ListCredentialsQuery, type ListCreditsTransactionsQuery, type ListCreditsTransactionsResponse, type ListPaymentsResponse, type ListSandboxesQuery, type ListScanHistoryQuery, type ListScanHistoryResponse, type ListScheduledTasksQuery, type ListScheduledTasksResponse, type LoginRequest, type MFASetupResponse, type MFASimpleResponse, type MFAStatus, MFAType, type MFAVerifyLoginRequest, type MFAVerifyLoginResponse, type MFAVerifySetupRequest, type MagicLinkActivateRequest, type MagicLinkSendResponse, type ModeType, type MonthlyCreditStats, NotImplementedError, type OpenChatStreamOptions, type OrgBudget, OrgRoles, type OrgSubscription, type Organization, type OrganizationUser, PROVIDER_CATALOG, type Payment, type PeekScanLeaseResponse, type PostChatMessageRequest, type PostChatMessageResponse, type Project, type ProjectMember, type ProviderID, type ProviderSpec, ProviderType, type PublicConfig, type Query, type ReconcileScope, type ReconcileTuple, type RefreshRequest, type RegisterRequest, type RequestOptions, type ResetPasswordRequest, type ResourceTreeCategory, type ResourceTreeCredential, type ResourceTreeGrouping, type ResourceTreeResource, type ResourceTreeResponse, ResourcesClient, type Sandbox, type SandboxCredential, type ScanInProgressError, type ScheduledTask, type ScopedBudget, type SessionResponse, type SessionTokens, type SimpleAgentResponse, type SimpleKeysResponse, type SimpleOrgResponse, type SimpleResponse$2 as SimpleResponse, type StorageType, type SubgraphDirection, type SubgraphRequest, type SubgraphResponse, type Subscription, type SubscriptionCapability, type SubscriptionPeriod, type SystemEvent, type SystemEventQuery, type SystemEventQueryResponse, type SystemEventReadResponse, type Template, type TokenProvider, type UnauthorizedHandler, type UpdateChatBudgetRequest, type UpdateChatScheduleRequest, type UpdateCostLimitRequest, type UpdateCredentialRequest, type UpdateMemberRoleRequest, type UpdateOrgBudgetRequest, type UpdateOrgUserRequest, type UpdateOrganizationRequest, type UpdateProjectRequest, type UpdateSandboxRequest, type UpdateScopedBudgetRequest, type UpdateUserRequest, type UpdateUserResponse, type UsageBucket, type UsageByModelQuery, type UsageByModelResponse, type UsageByModelRow, type UsageReportQuery, type UsageReportResponse, type UsageSummary, type UsageSummaryQuery, type UsageSummaryResponse, type UsageTotals, type UsageWindow, type UserProfile, type UserSummary, computeDisplayHint, getProvider, getValueAt, isMetadataPath, isSecretPath, listProviders, metadataKey, setValueAt, usdMicros, validate };
package/dist/index.d.ts CHANGED
@@ -143,12 +143,27 @@ interface SimpleResponse$2 {
143
143
  message?: string;
144
144
  error_code?: string;
145
145
  }
146
+ /**
147
+ * Unauthenticated config the SPA reads at boot (GET /public-config) to decide
148
+ * what to render before any session exists — e.g. whether self-service signup
149
+ * is available. Reflects the backend's OPEN_REGISTRATION at runtime.
150
+ */
151
+ interface PublicConfig {
152
+ openRegistration: boolean;
153
+ appName?: string;
154
+ }
146
155
 
147
156
  declare class AuthClient {
148
157
  private readonly http;
149
158
  constructor(http: BaseClient);
150
159
  login(body: LoginRequest): Promise<SessionResponse>;
151
160
  register(body: RegisterRequest): Promise<SessionResponse>;
161
+ /**
162
+ * Unauthenticated boot config. The SPA reads `openRegistration` to decide
163
+ * whether to render the self-service signup form (false => invite-only /
164
+ * preview mode). Safe to call before any session exists.
165
+ */
166
+ publicConfig(): Promise<PublicConfig>;
152
167
  logout(refreshToken?: string): Promise<SimpleResponse$2>;
153
168
  refresh(body: RefreshRequest): Promise<SessionResponse>;
154
169
  activate(body: ActivateRequest): Promise<SessionResponse>;
@@ -320,6 +335,31 @@ interface AcceptInviteRequest {
320
335
  token: string;
321
336
  password: string;
322
337
  }
338
+ /**
339
+ * Platform-admin payload for provisioning a brand-new organization and its
340
+ * founding owner in invite-only / preview mode (POST /organization/invite-org).
341
+ * The backend creates the org + owner (role=Owner, no password), provisions a
342
+ * subscription, and emails the owner an invite link. The owner finishes
343
+ * onboarding by accepting the invite (sets a password) or signing in via SSO.
344
+ */
345
+ interface InviteOrgRequest {
346
+ orgName: string;
347
+ website?: string;
348
+ isBusiness?: boolean;
349
+ owner: {
350
+ email: string;
351
+ firstName: string;
352
+ lastName?: string;
353
+ };
354
+ /** Override the configured free tier with a specific plan name. */
355
+ subscriptionName?: string;
356
+ /** Comped credit grant in USD micros; overrides the plan's default grant. */
357
+ creditsMicros?: number;
358
+ }
359
+ interface InviteOrgResult {
360
+ organization: Organization;
361
+ owner: OrganizationUser;
362
+ }
323
363
  interface SimpleOrgResponse {
324
364
  success: boolean;
325
365
  message?: string;
@@ -350,6 +390,14 @@ declare class OrganizationClient {
350
390
  name: string;
351
391
  allowDebug: boolean;
352
392
  }>>;
393
+ /**
394
+ * Platform-admin only: provision a new organization + founding owner and
395
+ * email the owner an invite link. The invite-only counterpart to public
396
+ * self-service registration (used while the backend has OPEN_REGISTRATION
397
+ * disabled). Returns 403 unless the caller's home org is the configured
398
+ * ADMIN_ORGANIZATION; 409 when the owner email already exists.
399
+ */
400
+ inviteOrg(body: InviteOrgRequest): Promise<InviteOrgResult>;
353
401
  /**
354
402
  * Platform-admin only: enable or disable the debug surface for an org.
355
403
  * Returns the updated org entry with the new allowDebug value.
@@ -468,7 +516,7 @@ interface UpdateCredentialRequest {
468
516
  interface ListCredentialsQuery {
469
517
  projectId: string;
470
518
  provider?: ProviderID;
471
- capability?: 'storage' | 'ai' | 'compute' | 'vcs';
519
+ capability?: 'storage' | 'ai' | 'compute' | 'vcs' | 'notify';
472
520
  }
473
521
  interface SandboxCredential {
474
522
  sandboxId: string;
@@ -528,6 +576,7 @@ declare const CAP_STORAGE = 1;
528
576
  declare const CAP_AI = 2;
529
577
  declare const CAP_COMPUTE = 4;
530
578
  declare const CAP_VCS = 8;
579
+ declare const CAP_NOTIFY = 16;
531
580
  declare const CAP_GENERAL = 255;
532
581
  interface ProviderSpec {
533
582
  id: string;
@@ -2023,4 +2072,4 @@ declare class NotImplementedError extends Error {
2023
2072
  constructor(method: string);
2024
2073
  }
2025
2074
 
2026
- export { type AcceptInviteRequest, AccessType, type AcquireScanLeaseRequest, type AcquireScanLeaseResponse, type ActionCategory, type ActivateRequest, type AddMemberRequest, type AnswerChatQuestionRequest, type AnswerChatQuestionResponse, type AuthUser, BaseClient, type BaseClientOptions, type BudgetScope, BudgetsClient, type BuyCustomCreditRequest, type BuyCustomCreditResponse, type BuySubscriptionRequest, type BuySubscriptionResponse, CAP_AI, CAP_COMPUTE, CAP_GENERAL, CAP_STORAGE, CAP_VCS, type CancelChatTurnResponse, type CancelSubscriptionResponse, type ChatAssistantMessagePayload, type ChatBillingRefuseCode, type ChatBillingRefuseError, type ChatBudget, type ChatCheckpointedPayload, type ChatCompactionFiredPayload, type ChatDonePayload, type ChatEvent, type ChatEventType, type ChatMessage, type ChatMessageKind, type ChatMessageRole, type ChatNarrationPayload, type ChatPhase, type ChatPhasePayload, type ChatPlanDraftPayload, type ChatQuestionPayload, type ChatSchedule, type ChatScheduleEnvelope, type ChatScheduleRunStatus, type ChatScope, type ChatSession, type ChatSessionSource, type ChatSessionTitlePayload, type ChatStepEventPayload, type ChatStepProgressPayload, type ChatStreamHandle, type ChatToolCallConfirmationRequiredPayload, type ChatToolCallFinishedPayload, type ChatToolCallStartedPayload, type ClarificationOption, CloudAgentClient, type CloudAgentClientOptions, type CloudResource, type CloudResourceContainerRef, type CloudResourceEdge, type CloudScanHistory, type CloudScanLease, type ConfirmChatToolCallRequest, type ConfirmChatToolCallResponse, type CreateAgentTemplateRequest, type CreateChatScheduleRequest, type CreateChatSessionRequest, type CreateChatSessionResponse, type CreateCredentialRequest, type CreateGatewayTokenRequest, type CreateGatewayTokenResponse, type CreateOrganizationUserRequest, type CreateProjectRequest, type CreateSandboxRequest, type CreateScheduledTaskRequest, type Credential, type CreditBalance, type CreditTransaction, type CreditTransactionKind, type CreditTransactionType, type CustomCreditPurchaseConfig, type DebugPayload, type DebugReceipt, type EffectiveChatBudget, type ExchangeCodeRequest, type FieldSpec, type FieldType, type FineTuneParams, type GatewayToken, type GetChatSessionResponse, type GetUsageSummaryQuery, type GetUsageSummaryResponse, HttpError, type ImpersonationProvider, type ListAgentTemplatesQuery, type ListAgentTemplatesResponse, type ListChatScheduleRunsResponse, type ListChatSchedulesResponse, type ListChatSessionsQuery, type ListChatSessionsResponse, type ListCredentialsQuery, type ListCreditsTransactionsQuery, type ListCreditsTransactionsResponse, type ListPaymentsResponse, type ListSandboxesQuery, type ListScanHistoryQuery, type ListScanHistoryResponse, type ListScheduledTasksQuery, type ListScheduledTasksResponse, type LoginRequest, type MFASetupResponse, type MFASimpleResponse, type MFAStatus, MFAType, type MFAVerifyLoginRequest, type MFAVerifyLoginResponse, type MFAVerifySetupRequest, type MagicLinkActivateRequest, type MagicLinkSendResponse, type ModeType, type MonthlyCreditStats, NotImplementedError, type OpenChatStreamOptions, type OrgBudget, OrgRoles, type OrgSubscription, type Organization, type OrganizationUser, PROVIDER_CATALOG, type Payment, type PeekScanLeaseResponse, type PostChatMessageRequest, type PostChatMessageResponse, type Project, type ProjectMember, type ProviderID, type ProviderSpec, ProviderType, type Query, type ReconcileScope, type ReconcileTuple, type RefreshRequest, type RegisterRequest, type RequestOptions, type ResetPasswordRequest, type ResourceTreeCategory, type ResourceTreeCredential, type ResourceTreeGrouping, type ResourceTreeResource, type ResourceTreeResponse, ResourcesClient, type Sandbox, type SandboxCredential, type ScanInProgressError, type ScheduledTask, type ScopedBudget, type SessionResponse, type SessionTokens, type SimpleAgentResponse, type SimpleKeysResponse, type SimpleOrgResponse, type SimpleResponse$2 as SimpleResponse, type StorageType, type SubgraphDirection, type SubgraphRequest, type SubgraphResponse, type Subscription, type SubscriptionCapability, type SubscriptionPeriod, type SystemEvent, type SystemEventQuery, type SystemEventQueryResponse, type SystemEventReadResponse, type Template, type TokenProvider, type UnauthorizedHandler, type UpdateChatBudgetRequest, type UpdateChatScheduleRequest, type UpdateCostLimitRequest, type UpdateCredentialRequest, type UpdateMemberRoleRequest, type UpdateOrgBudgetRequest, type UpdateOrgUserRequest, type UpdateOrganizationRequest, type UpdateProjectRequest, type UpdateSandboxRequest, type UpdateScopedBudgetRequest, type UpdateUserRequest, type UpdateUserResponse, type UsageBucket, type UsageByModelQuery, type UsageByModelResponse, type UsageByModelRow, type UsageReportQuery, type UsageReportResponse, type UsageSummary, type UsageSummaryQuery, type UsageSummaryResponse, type UsageTotals, type UsageWindow, type UserProfile, type UserSummary, computeDisplayHint, getProvider, getValueAt, isMetadataPath, isSecretPath, listProviders, metadataKey, setValueAt, usdMicros, validate };
2075
+ export { type AcceptInviteRequest, AccessType, type AcquireScanLeaseRequest, type AcquireScanLeaseResponse, type ActionCategory, type ActivateRequest, type AddMemberRequest, type AnswerChatQuestionRequest, type AnswerChatQuestionResponse, type AuthUser, BaseClient, type BaseClientOptions, type BudgetScope, BudgetsClient, type BuyCustomCreditRequest, type BuyCustomCreditResponse, type BuySubscriptionRequest, type BuySubscriptionResponse, CAP_AI, CAP_COMPUTE, CAP_GENERAL, CAP_NOTIFY, CAP_STORAGE, CAP_VCS, type CancelChatTurnResponse, type CancelSubscriptionResponse, type ChatAssistantMessagePayload, type ChatBillingRefuseCode, type ChatBillingRefuseError, type ChatBudget, type ChatCheckpointedPayload, type ChatCompactionFiredPayload, type ChatDonePayload, type ChatEvent, type ChatEventType, type ChatMessage, type ChatMessageKind, type ChatMessageRole, type ChatNarrationPayload, type ChatPhase, type ChatPhasePayload, type ChatPlanDraftPayload, type ChatQuestionPayload, type ChatSchedule, type ChatScheduleEnvelope, type ChatScheduleRunStatus, type ChatScope, type ChatSession, type ChatSessionSource, type ChatSessionTitlePayload, type ChatStepEventPayload, type ChatStepProgressPayload, type ChatStreamHandle, type ChatToolCallConfirmationRequiredPayload, type ChatToolCallFinishedPayload, type ChatToolCallStartedPayload, type ClarificationOption, CloudAgentClient, type CloudAgentClientOptions, type CloudResource, type CloudResourceContainerRef, type CloudResourceEdge, type CloudScanHistory, type CloudScanLease, type ConfirmChatToolCallRequest, type ConfirmChatToolCallResponse, type CreateAgentTemplateRequest, type CreateChatScheduleRequest, type CreateChatSessionRequest, type CreateChatSessionResponse, type CreateCredentialRequest, type CreateGatewayTokenRequest, type CreateGatewayTokenResponse, type CreateOrganizationUserRequest, type CreateProjectRequest, type CreateSandboxRequest, type CreateScheduledTaskRequest, type Credential, type CreditBalance, type CreditTransaction, type CreditTransactionKind, type CreditTransactionType, type CustomCreditPurchaseConfig, type DebugPayload, type DebugReceipt, type EffectiveChatBudget, type ExchangeCodeRequest, type FieldSpec, type FieldType, type FineTuneParams, type GatewayToken, type GetChatSessionResponse, type GetUsageSummaryQuery, type GetUsageSummaryResponse, HttpError, type ImpersonationProvider, type InviteOrgRequest, type InviteOrgResult, type ListAgentTemplatesQuery, type ListAgentTemplatesResponse, type ListChatScheduleRunsResponse, type ListChatSchedulesResponse, type ListChatSessionsQuery, type ListChatSessionsResponse, type ListCredentialsQuery, type ListCreditsTransactionsQuery, type ListCreditsTransactionsResponse, type ListPaymentsResponse, type ListSandboxesQuery, type ListScanHistoryQuery, type ListScanHistoryResponse, type ListScheduledTasksQuery, type ListScheduledTasksResponse, type LoginRequest, type MFASetupResponse, type MFASimpleResponse, type MFAStatus, MFAType, type MFAVerifyLoginRequest, type MFAVerifyLoginResponse, type MFAVerifySetupRequest, type MagicLinkActivateRequest, type MagicLinkSendResponse, type ModeType, type MonthlyCreditStats, NotImplementedError, type OpenChatStreamOptions, type OrgBudget, OrgRoles, type OrgSubscription, type Organization, type OrganizationUser, PROVIDER_CATALOG, type Payment, type PeekScanLeaseResponse, type PostChatMessageRequest, type PostChatMessageResponse, type Project, type ProjectMember, type ProviderID, type ProviderSpec, ProviderType, type PublicConfig, type Query, type ReconcileScope, type ReconcileTuple, type RefreshRequest, type RegisterRequest, type RequestOptions, type ResetPasswordRequest, type ResourceTreeCategory, type ResourceTreeCredential, type ResourceTreeGrouping, type ResourceTreeResource, type ResourceTreeResponse, ResourcesClient, type Sandbox, type SandboxCredential, type ScanInProgressError, type ScheduledTask, type ScopedBudget, type SessionResponse, type SessionTokens, type SimpleAgentResponse, type SimpleKeysResponse, type SimpleOrgResponse, type SimpleResponse$2 as SimpleResponse, type StorageType, type SubgraphDirection, type SubgraphRequest, type SubgraphResponse, type Subscription, type SubscriptionCapability, type SubscriptionPeriod, type SystemEvent, type SystemEventQuery, type SystemEventQueryResponse, type SystemEventReadResponse, type Template, type TokenProvider, type UnauthorizedHandler, type UpdateChatBudgetRequest, type UpdateChatScheduleRequest, type UpdateCostLimitRequest, type UpdateCredentialRequest, type UpdateMemberRoleRequest, type UpdateOrgBudgetRequest, type UpdateOrgUserRequest, type UpdateOrganizationRequest, type UpdateProjectRequest, type UpdateSandboxRequest, type UpdateScopedBudgetRequest, type UpdateUserRequest, type UpdateUserResponse, type UsageBucket, type UsageByModelQuery, type UsageByModelResponse, type UsageByModelRow, type UsageReportQuery, type UsageReportResponse, type UsageSummary, type UsageSummaryQuery, type UsageSummaryResponse, type UsageTotals, type UsageWindow, type UserProfile, type UserSummary, computeDisplayHint, getProvider, getValueAt, isMetadataPath, isSecretPath, listProviders, metadataKey, setValueAt, usdMicros, validate };
package/dist/index.js CHANGED
@@ -136,6 +136,14 @@ var AuthClient = class {
136
136
  register(body) {
137
137
  return this.http.post("/user/register", { body, skipAuth: true });
138
138
  }
139
+ /**
140
+ * Unauthenticated boot config. The SPA reads `openRegistration` to decide
141
+ * whether to render the self-service signup form (false => invite-only /
142
+ * preview mode). Safe to call before any session exists.
143
+ */
144
+ publicConfig() {
145
+ return this.http.get("/public-config", { skipAuth: true });
146
+ }
139
147
  logout(refreshToken) {
140
148
  return this.http.post("/user/logout", {
141
149
  body: { refreshToken }
@@ -270,6 +278,20 @@ var OrganizationClient = class {
270
278
  const res = await this.http.get("/orgs/list-all");
271
279
  return res.data ?? [];
272
280
  }
281
+ /**
282
+ * Platform-admin only: provision a new organization + founding owner and
283
+ * email the owner an invite link. The invite-only counterpart to public
284
+ * self-service registration (used while the backend has OPEN_REGISTRATION
285
+ * disabled). Returns 403 unless the caller's home org is the configured
286
+ * ADMIN_ORGANIZATION; 409 when the owner email already exists.
287
+ */
288
+ async inviteOrg(body) {
289
+ const res = await this.http.post(
290
+ "/organization/invite-org",
291
+ { body }
292
+ );
293
+ return unwrapData(res);
294
+ }
273
295
  /**
274
296
  * Platform-admin only: enable or disable the debug surface for an org.
275
297
  * Returns the updated org entry with the new allowDebug value.
@@ -1164,6 +1186,7 @@ var CAP_STORAGE = 1;
1164
1186
  var CAP_AI = 2;
1165
1187
  var CAP_COMPUTE = 4;
1166
1188
  var CAP_VCS = 8;
1189
+ var CAP_NOTIFY = 16;
1167
1190
  var CAP_GENERAL = 255;
1168
1191
  var PROVIDER_CATALOG = {
1169
1192
  AWS: {
@@ -1551,9 +1574,113 @@ var PROVIDER_CATALOG = {
1551
1574
  help: "Override for proxies or regional endpoints. Most users leave blank to use the default Gemini API base URL."
1552
1575
  }
1553
1576
  ]
1577
+ },
1578
+ SLACK: {
1579
+ id: "SLACK",
1580
+ displayName: "Slack",
1581
+ capabilities: CAP_NOTIFY,
1582
+ fields: [
1583
+ {
1584
+ path: "secret",
1585
+ label: "Incoming Webhook URL",
1586
+ type: "password",
1587
+ required: true,
1588
+ secret: true,
1589
+ placeholder: "https://hooks.slack.com/services/T000/B000/xxxxxxxx",
1590
+ help: "A Slack Incoming Webhook URL. The target channel is fixed by the webhook. Encrypted at rest; never injected into the sandbox."
1591
+ },
1592
+ {
1593
+ path: "metadata.channelHint",
1594
+ label: "Channel Hint (optional)",
1595
+ type: "text",
1596
+ required: false,
1597
+ placeholder: "#oncall",
1598
+ help: "Display-only label for the channel this webhook posts to. Does not change routing \u2014 the webhook URL controls the destination."
1599
+ }
1600
+ ]
1601
+ },
1602
+ TEAMS: {
1603
+ id: "TEAMS",
1604
+ displayName: "Microsoft Teams",
1605
+ capabilities: CAP_NOTIFY,
1606
+ fields: [
1607
+ {
1608
+ path: "secret",
1609
+ label: "Incoming Webhook URL",
1610
+ type: "password",
1611
+ required: true,
1612
+ secret: true,
1613
+ placeholder: "https://outlook.office.com/webhook/...",
1614
+ help: "A Teams Incoming Webhook (connector) URL. The target channel is fixed by the webhook. Encrypted at rest; never injected into the sandbox."
1615
+ }
1616
+ ]
1617
+ },
1618
+ PAGERDUTY: {
1619
+ id: "PAGERDUTY",
1620
+ displayName: "PagerDuty",
1621
+ capabilities: CAP_NOTIFY,
1622
+ fields: [
1623
+ {
1624
+ path: "secret",
1625
+ label: "Integration / Routing Key",
1626
+ type: "password",
1627
+ required: true,
1628
+ secret: true,
1629
+ placeholder: "R0XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
1630
+ help: "An Events API v2 integration (routing) key from a PagerDuty service. Encrypted at rest; never injected into the sandbox."
1631
+ }
1632
+ ]
1633
+ },
1634
+ SMTP: {
1635
+ id: "SMTP",
1636
+ displayName: "Email (SMTP)",
1637
+ capabilities: CAP_NOTIFY,
1638
+ fields: [
1639
+ {
1640
+ path: "metadata.host",
1641
+ label: "SMTP Host",
1642
+ type: "text",
1643
+ required: true,
1644
+ placeholder: "smtp.example.com",
1645
+ help: "Hostname of the SMTP relay."
1646
+ },
1647
+ {
1648
+ path: "metadata.port",
1649
+ label: "Port",
1650
+ type: "number",
1651
+ required: false,
1652
+ default: 587,
1653
+ placeholder: "587",
1654
+ help: "SMTP port. Defaults to 587 (STARTTLS). TLS is always required."
1655
+ },
1656
+ {
1657
+ path: "metadata.fromAddress",
1658
+ label: "From Address",
1659
+ type: "text",
1660
+ required: true,
1661
+ placeholder: "alerts@example.com",
1662
+ help: "Envelope-from / From header for messages the agent sends. Also used as the SMTP AUTH username."
1663
+ },
1664
+ {
1665
+ path: "metadata.toAddresses",
1666
+ label: "To Addresses",
1667
+ type: "stringList",
1668
+ required: true,
1669
+ placeholder: "oncall@example.com",
1670
+ help: "One or more recipient addresses. Every notify message is sent to all of them."
1671
+ },
1672
+ {
1673
+ path: "secret",
1674
+ label: "Password",
1675
+ type: "password",
1676
+ required: true,
1677
+ secret: true,
1678
+ help: "SMTP AUTH password for the From address. Encrypted at rest; never injected into the sandbox."
1679
+ }
1680
+ ]
1554
1681
  }
1555
1682
  };
1556
- var PROVIDER_ORDER = ["AWS", "BEDROCK", "GCP", "AZURE", "SSH", "GITHUB", "GITLAB", "AZURE_DEVOPS", "OPENAI", "ANTHROPIC", "GEMINI"];
1683
+ var PROVIDER_ORDER = ["AWS", "BEDROCK", "GCP", "AZURE", "SSH", "GITHUB", "GITLAB", "AZURE_DEVOPS", "OPENAI", "ANTHROPIC", "GEMINI", "SLACK", "TEAMS", "PAGERDUTY", "SMTP"];
1557
1684
  function listProviders() {
1558
1685
  return PROVIDER_ORDER.flatMap((id) => PROVIDER_CATALOG[id] ? [PROVIDER_CATALOG[id]] : []);
1559
1686
  }
@@ -1765,6 +1892,13 @@ function computeDisplayHint(providerId, metadata) {
1765
1892
  const prefix = str(metadata["tokenPrefix"]);
1766
1893
  return prefix ? `${prefix}\u2026` : "";
1767
1894
  }
1895
+ case "SLACK":
1896
+ return str(metadata["channelHint"]);
1897
+ case "SMTP": {
1898
+ const from = str(metadata["fromAddress"]);
1899
+ const host = str(metadata["host"]);
1900
+ return from + (host ? ` @ ${host}` : "");
1901
+ }
1768
1902
  default:
1769
1903
  return "";
1770
1904
  }
@@ -1792,6 +1926,6 @@ var usdMicros = {
1792
1926
  fromDollars: (dollars) => Math.round(dollars * 1e6)
1793
1927
  };
1794
1928
 
1795
- export { AccessType, BaseClient, BudgetsClient, CAP_AI, CAP_COMPUTE, CAP_GENERAL, CAP_STORAGE, CAP_VCS, CloudAgentClient, HttpError, MFAType, NotImplementedError, OrgRoles, PROVIDER_CATALOG, ProviderType, ResourcesClient, computeDisplayHint, getProvider, getValueAt, isMetadataPath, isSecretPath, listProviders, metadataKey, setValueAt, usdMicros, validate };
1929
+ export { AccessType, BaseClient, BudgetsClient, CAP_AI, CAP_COMPUTE, CAP_GENERAL, CAP_NOTIFY, CAP_STORAGE, CAP_VCS, CloudAgentClient, HttpError, MFAType, NotImplementedError, OrgRoles, PROVIDER_CATALOG, ProviderType, ResourcesClient, computeDisplayHint, getProvider, getValueAt, isMetadataPath, isSecretPath, listProviders, metadataKey, setValueAt, usdMicros, validate };
1796
1930
  //# sourceMappingURL=index.js.map
1797
1931
  //# sourceMappingURL=index.js.map