@alva-ai/toolkit 0.15.0 → 0.15.1-beta.0

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
@@ -307,6 +307,56 @@ interface FeedDeleteRequest {
307
307
  /** Numeric feed id to delete. */
308
308
  id: number;
309
309
  }
310
+ type FeedListStatus = 'active' | 'paused' | 'all';
311
+ interface FeedListParams {
312
+ /** Page size, default 50, max 100 server-side. */
313
+ limit?: number;
314
+ /** Opaque cursor token from the previous page. */
315
+ cursor?: string;
316
+ /** Runtime status filter; defaults to active on the gateway. */
317
+ status?: FeedListStatus;
318
+ }
319
+ interface FeedListItem {
320
+ /** Numeric feed id encoded as a string, matching the gateway response. */
321
+ id: string;
322
+ name: string;
323
+ /** Feed runtime status. */
324
+ status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | (string & {});
325
+ cron_expression?: string;
326
+ total_runs: number;
327
+ used_by_total: number;
328
+ }
329
+ interface FeedListResponse {
330
+ feeds: FeedListItem[];
331
+ next_cursor?: string;
332
+ has_more: boolean;
333
+ }
334
+ interface AutomationInspectRequest {
335
+ /** Numeric automation id. Currently the same underlying feed id. */
336
+ id: number;
337
+ }
338
+ interface AutomationInspectResponse {
339
+ /** Numeric automation id encoded as a string, matching the gateway response. */
340
+ id: string;
341
+ /** Backing feed id encoded as a string. */
342
+ feed_id: string;
343
+ name: string;
344
+ description?: string;
345
+ /** Automation runtime status. */
346
+ status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | (string & {});
347
+ cron_expression?: string;
348
+ total_runs: number;
349
+ /**
350
+ * Backend product-flow registry id. Null for ordinary non-flow automations.
351
+ */
352
+ flow_id: string | null;
353
+ /**
354
+ * Absolute ALFS config path for caller-owned product-flow automations.
355
+ * Null for ordinary automations and product-flow automations not owned by
356
+ * the caller.
357
+ */
358
+ flow_config_path: string | null;
359
+ }
310
360
  interface FeedStatusUpdateRequest {
311
361
  /** Numeric feed id to stop/resume. */
312
362
  id: number;
@@ -315,7 +365,7 @@ interface FeedStatusUpdateResponse {
315
365
  /** Echoed feed id (string form, matching gateway response). */
316
366
  id: string;
317
367
  /** Feed runtime status after the update. */
318
- status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | string;
368
+ status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | (string & {});
319
369
  }
320
370
  interface FeedDeleteResponse {
321
371
  /** Echoed feed id (string form, matching gateway response). */
@@ -995,6 +1045,10 @@ declare class ReleaseResource {
995
1045
  declare class FeedResource {
996
1046
  private client;
997
1047
  constructor(client: AlvaClient);
1048
+ /**
1049
+ * List feeds owned by the caller. Backed by GET /api/v1/feed.
1050
+ */
1051
+ list(params?: FeedListParams): Promise<FeedListResponse>;
998
1052
  /**
999
1053
  * Stop a feed's producer cronjob. This pauses future scheduled runs while
1000
1054
  * preserving the feed and its existing data.
@@ -1019,6 +1073,24 @@ declare class FeedResource {
1019
1073
  delete(params: FeedDeleteRequest): Promise<FeedDeleteResponse>;
1020
1074
  }
1021
1075
 
1076
+ /**
1077
+ * Product-facing automation API. Backed by the existing feed/release gateway
1078
+ * surfaces while those lower-level names remain on the wire for compatibility.
1079
+ */
1080
+ declare class AutomationResource {
1081
+ private client;
1082
+ constructor(client: AlvaClient);
1083
+ list(params?: FeedListParams): Promise<FeedListResponse>;
1084
+ /**
1085
+ * Inspect one automation. Backed by GET /api/v1/automation/:id.
1086
+ */
1087
+ inspect(params: AutomationInspectRequest): Promise<AutomationInspectResponse>;
1088
+ stop(params: FeedStatusUpdateRequest): Promise<FeedStatusUpdateResponse>;
1089
+ resume(params: FeedStatusUpdateRequest): Promise<FeedStatusUpdateResponse>;
1090
+ delete(params: FeedDeleteRequest): Promise<FeedDeleteResponse>;
1091
+ publish(params: FeedReleaseRequest): Promise<FeedReleaseResponse>;
1092
+ }
1093
+
1022
1094
  /** Playbook visibility states understood by the gateway. */
1023
1095
  type PlaybookVisibility = 'public' | 'private' | 'paid';
1024
1096
  interface SetVisibilityParams {
@@ -1473,6 +1545,25 @@ declare class SubscriptionsResource {
1473
1545
  unsubscribeBatch(params: UnsubscribeBatchParams): Promise<UnsubscribeBatchResponse>;
1474
1546
  }
1475
1547
 
1548
+ /**
1549
+ * Product-facing alert API. The current transport still calls the legacy
1550
+ * subscription and notification-history endpoints.
1551
+ */
1552
+ declare class AlertsResource {
1553
+ private client;
1554
+ constructor(client: AlvaClient);
1555
+ list(params?: PushSubscriptionListParams): Promise<PushSubscriptionListResponse>;
1556
+ enableAutomation(params: PushSubscriptionFeedParams): Promise<SubscribeFeedResponse>;
1557
+ disableAutomation(params: PushSubscriptionFeedParams): Promise<UnsubscribeResponse>;
1558
+ enablePlaybook(params: PushSubscriptionPlaybookParams): Promise<SubscribePlaybookResponse>;
1559
+ disablePlaybook(params: PushSubscriptionPlaybookParams): Promise<UnsubscribeResponse>;
1560
+ disableBatch(params: UnsubscribeBatchParams): Promise<UnsubscribeBatchResponse>;
1561
+ historyAutomation(params: NotificationListParams): Promise<FeedNotificationListResponse>;
1562
+ historyPlaybook(params: NotificationListParams): Promise<PlaybookNotificationListResponse>;
1563
+ preferences(): Promise<NotificationPreferencesResponse>;
1564
+ updatePreference(params: NotificationPreferenceUpdateParams): Promise<NotificationPreferenceUpdateResponse>;
1565
+ }
1566
+
1476
1567
  /**
1477
1568
  * Group push subscriptions for an external channel session.
1478
1569
  *
@@ -1640,6 +1731,7 @@ declare class AlvaClient {
1640
1731
  private _serviceAccount?;
1641
1732
  private _release?;
1642
1733
  private _feed?;
1734
+ private _automation?;
1643
1735
  private _playbooks?;
1644
1736
  private _secrets?;
1645
1737
  private _sdk?;
@@ -1655,6 +1747,7 @@ declare class AlvaClient {
1655
1747
  private _notifications?;
1656
1748
  private _notificationPreferences?;
1657
1749
  private _subscriptions?;
1750
+ private _alerts?;
1658
1751
  private _channelGroupSubscriptions?;
1659
1752
  private _feedback?;
1660
1753
  private _functions?;
@@ -1666,6 +1759,7 @@ declare class AlvaClient {
1666
1759
  get serviceAccount(): ServiceAccountResource;
1667
1760
  get release(): ReleaseResource;
1668
1761
  get feed(): FeedResource;
1762
+ get automation(): AutomationResource;
1669
1763
  get playbooks(): PlaybooksResource;
1670
1764
  get secrets(): SecretsResource;
1671
1765
  get sdk(): SdkDocsResource;
@@ -1681,6 +1775,7 @@ declare class AlvaClient {
1681
1775
  get notifications(): NotificationsResource;
1682
1776
  get notificationPreferences(): NotificationPreferencesResource;
1683
1777
  get subscriptions(): SubscriptionsResource;
1778
+ get alerts(): AlertsResource;
1684
1779
  get channelGroupSubscriptions(): ChannelGroupSubscriptionsResource;
1685
1780
  get feedback(): FeedbackResource;
1686
1781
  get functions(): FunctionsResource;
@@ -1833,4 +1928,4 @@ declare const installPlaybookRuntime: (targetWindow?: Window) => void;
1833
1928
  /** SDK version, injected at build time from package.json. */
1834
1929
  declare const VERSION: string;
1835
1930
 
1836
- export { AlvaClient, type AlvaClientConfig, AlvaError, type ChannelGroupAdminInfo, type ChannelGroupCallerInfo, type ChannelGroupSubscription, type ChannelGroupSubscriptionContextResponse, type ChannelGroupSubscriptionListResponse, type ChannelGroupSubscriptionMutationParams, type ChannelGroupSubscriptionMutationResponse, type ChannelGroupSubscriptionSessionParams, type ChannelGroupSubscriptionTarget, type ChannelGroupSubscriptionTargetType, CliUsageError, type CreateAllowanceParams, type CreateAllowanceResponse, type CreditAllowance, type CreditWallet, type CreditWalletItem, type CreditWalletItemConnection, type CreditWalletItemEdge, type CreditWalletItemsParams, type CreditWalletItemsResponse, type CreditWalletPageInfo, type DeleteFunctionParams, type FeedDeleteRequest, type FeedDeleteResponse, type FeedStatusUpdateRequest, type FeedStatusUpdateResponse, type FsChmodParams, type FsCopyParams, type FsEntry, type FsGrantParams, type FsMkdirParams, type FsRawWriteParams, type FsReadParams, type FsReaddirParams, type FsReaddirResponse, type FsReadlinkParams, type FsRemoveParams, type FsRenameParams, type FsRevokeParams, type FsStat, type FsSymlinkParams, type FsWriteParams, type FsWriteResponse, type GetAllowanceParams, type InvokeFunctionParams, type InvokeFunctionResponse, type ListAllowancesResponse, type ListFunctionsParams, type ListFunctionsResponse, type NotificationPreference, type NotificationPreferenceKey, type NotificationPreferenceUpdateParams, type NotificationPreferenceUpdateResponse, type NotificationPreferencesResponse, PBSV_UPDATE_MESSAGE, type PlaybookFunction, type PlaybookSkillFile, type PlaybookSkillFileMeta, type PlaybookSkillMeta, type PlaybookSkillSummary, type PlaybookSkillTagEntry, type RegisterFunctionParams, type RegisterFunctionResponse, type RevokeAllowanceParams, type RevokeAllowanceResponse, SUBSCRIBE_PROPOSE_MESSAGE, SUBSCRIBE_RESULT_MESSAGE, type SkillDoc, type SkillEndpointMetadata, type SkillEndpointTier, type SkillMetadata, type SkillSummary, type SubmitFeedbackRequest, type SubmitFeedbackResponse, type SubscribeApi, type SubscribeProposalInput, type SubscribeProposalResult, type TrendingPlaybookItem, type TrendingPlaybooksDir, type TrendingPlaybooksParams, type TrendingPlaybooksResponse, type TrendingPlaybooksSort, UDF_AUTH_REQUIRED_MESSAGE, UDF_CONSENT_REQUEST_MESSAGE, UDF_CONSENT_RESPONSE_MESSAGE, type UdfApi, UdfAuthRequiredError, type UdfButtonEventDetail, type UdfButtonOptions, UdfConsentDeniedError, UdfConsentRequiredError, UdfConsentTimeoutError, type UdfDescriptor, UdfError, UdfExecutionError, UdfFunctionDisabledError, UdfFunctionNotFoundError, UdfInsufficientCredits, type UdfInvokeResponse, UdfPidMismatchError, UdfRateLimitedError, UdfTokenExpiredError, UdfTokenInvalidError, UdfTransportError, VERSION, getViewerToken, installPlaybookRuntime, mapUdfErrorResponse, playbookIdFromToken, subscribe, udf };
1931
+ export { AlertsResource, AlvaClient, type AlvaClientConfig, AlvaError, AutomationResource, type ChannelGroupAdminInfo, type ChannelGroupCallerInfo, type ChannelGroupSubscription, type ChannelGroupSubscriptionContextResponse, type ChannelGroupSubscriptionListResponse, type ChannelGroupSubscriptionMutationParams, type ChannelGroupSubscriptionMutationResponse, type ChannelGroupSubscriptionSessionParams, type ChannelGroupSubscriptionTarget, type ChannelGroupSubscriptionTargetType, CliUsageError, type CreateAllowanceParams, type CreateAllowanceResponse, type CreditAllowance, type CreditWallet, type CreditWalletItem, type CreditWalletItemConnection, type CreditWalletItemEdge, type CreditWalletItemsParams, type CreditWalletItemsResponse, type CreditWalletPageInfo, type DeleteFunctionParams, type FeedDeleteRequest, type FeedDeleteResponse, type FeedListItem, type FeedListParams, type FeedListResponse, type FeedListStatus, type FeedStatusUpdateRequest, type FeedStatusUpdateResponse, type FsChmodParams, type FsCopyParams, type FsEntry, type FsGrantParams, type FsMkdirParams, type FsRawWriteParams, type FsReadParams, type FsReaddirParams, type FsReaddirResponse, type FsReadlinkParams, type FsRemoveParams, type FsRenameParams, type FsRevokeParams, type FsStat, type FsSymlinkParams, type FsWriteParams, type FsWriteResponse, type GetAllowanceParams, type InvokeFunctionParams, type InvokeFunctionResponse, type ListAllowancesResponse, type ListFunctionsParams, type ListFunctionsResponse, type NotificationPreference, type NotificationPreferenceKey, type NotificationPreferenceUpdateParams, type NotificationPreferenceUpdateResponse, type NotificationPreferencesResponse, PBSV_UPDATE_MESSAGE, type PlaybookFunction, type PlaybookSkillFile, type PlaybookSkillFileMeta, type PlaybookSkillMeta, type PlaybookSkillSummary, type PlaybookSkillTagEntry, type RegisterFunctionParams, type RegisterFunctionResponse, type RevokeAllowanceParams, type RevokeAllowanceResponse, SUBSCRIBE_PROPOSE_MESSAGE, SUBSCRIBE_RESULT_MESSAGE, type SkillDoc, type SkillEndpointMetadata, type SkillEndpointTier, type SkillMetadata, type SkillSummary, type SubmitFeedbackRequest, type SubmitFeedbackResponse, type SubscribeApi, type SubscribeProposalInput, type SubscribeProposalResult, type TrendingPlaybookItem, type TrendingPlaybooksDir, type TrendingPlaybooksParams, type TrendingPlaybooksResponse, type TrendingPlaybooksSort, UDF_AUTH_REQUIRED_MESSAGE, UDF_CONSENT_REQUEST_MESSAGE, UDF_CONSENT_RESPONSE_MESSAGE, type UdfApi, UdfAuthRequiredError, type UdfButtonEventDetail, type UdfButtonOptions, UdfConsentDeniedError, UdfConsentRequiredError, UdfConsentTimeoutError, type UdfDescriptor, UdfError, UdfExecutionError, UdfFunctionDisabledError, UdfFunctionNotFoundError, UdfInsufficientCredits, type UdfInvokeResponse, UdfPidMismatchError, UdfRateLimitedError, UdfTokenExpiredError, UdfTokenInvalidError, UdfTransportError, VERSION, getViewerToken, installPlaybookRuntime, mapUdfErrorResponse, playbookIdFromToken, subscribe, udf };
package/dist/index.d.ts CHANGED
@@ -307,6 +307,56 @@ interface FeedDeleteRequest {
307
307
  /** Numeric feed id to delete. */
308
308
  id: number;
309
309
  }
310
+ type FeedListStatus = 'active' | 'paused' | 'all';
311
+ interface FeedListParams {
312
+ /** Page size, default 50, max 100 server-side. */
313
+ limit?: number;
314
+ /** Opaque cursor token from the previous page. */
315
+ cursor?: string;
316
+ /** Runtime status filter; defaults to active on the gateway. */
317
+ status?: FeedListStatus;
318
+ }
319
+ interface FeedListItem {
320
+ /** Numeric feed id encoded as a string, matching the gateway response. */
321
+ id: string;
322
+ name: string;
323
+ /** Feed runtime status. */
324
+ status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | (string & {});
325
+ cron_expression?: string;
326
+ total_runs: number;
327
+ used_by_total: number;
328
+ }
329
+ interface FeedListResponse {
330
+ feeds: FeedListItem[];
331
+ next_cursor?: string;
332
+ has_more: boolean;
333
+ }
334
+ interface AutomationInspectRequest {
335
+ /** Numeric automation id. Currently the same underlying feed id. */
336
+ id: number;
337
+ }
338
+ interface AutomationInspectResponse {
339
+ /** Numeric automation id encoded as a string, matching the gateway response. */
340
+ id: string;
341
+ /** Backing feed id encoded as a string. */
342
+ feed_id: string;
343
+ name: string;
344
+ description?: string;
345
+ /** Automation runtime status. */
346
+ status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | (string & {});
347
+ cron_expression?: string;
348
+ total_runs: number;
349
+ /**
350
+ * Backend product-flow registry id. Null for ordinary non-flow automations.
351
+ */
352
+ flow_id: string | null;
353
+ /**
354
+ * Absolute ALFS config path for caller-owned product-flow automations.
355
+ * Null for ordinary automations and product-flow automations not owned by
356
+ * the caller.
357
+ */
358
+ flow_config_path: string | null;
359
+ }
310
360
  interface FeedStatusUpdateRequest {
311
361
  /** Numeric feed id to stop/resume. */
312
362
  id: number;
@@ -315,7 +365,7 @@ interface FeedStatusUpdateResponse {
315
365
  /** Echoed feed id (string form, matching gateway response). */
316
366
  id: string;
317
367
  /** Feed runtime status after the update. */
318
- status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | string;
368
+ status: 'ACTIVE' | 'PAUSED' | 'UNSPECIFIED' | (string & {});
319
369
  }
320
370
  interface FeedDeleteResponse {
321
371
  /** Echoed feed id (string form, matching gateway response). */
@@ -995,6 +1045,10 @@ declare class ReleaseResource {
995
1045
  declare class FeedResource {
996
1046
  private client;
997
1047
  constructor(client: AlvaClient);
1048
+ /**
1049
+ * List feeds owned by the caller. Backed by GET /api/v1/feed.
1050
+ */
1051
+ list(params?: FeedListParams): Promise<FeedListResponse>;
998
1052
  /**
999
1053
  * Stop a feed's producer cronjob. This pauses future scheduled runs while
1000
1054
  * preserving the feed and its existing data.
@@ -1019,6 +1073,24 @@ declare class FeedResource {
1019
1073
  delete(params: FeedDeleteRequest): Promise<FeedDeleteResponse>;
1020
1074
  }
1021
1075
 
1076
+ /**
1077
+ * Product-facing automation API. Backed by the existing feed/release gateway
1078
+ * surfaces while those lower-level names remain on the wire for compatibility.
1079
+ */
1080
+ declare class AutomationResource {
1081
+ private client;
1082
+ constructor(client: AlvaClient);
1083
+ list(params?: FeedListParams): Promise<FeedListResponse>;
1084
+ /**
1085
+ * Inspect one automation. Backed by GET /api/v1/automation/:id.
1086
+ */
1087
+ inspect(params: AutomationInspectRequest): Promise<AutomationInspectResponse>;
1088
+ stop(params: FeedStatusUpdateRequest): Promise<FeedStatusUpdateResponse>;
1089
+ resume(params: FeedStatusUpdateRequest): Promise<FeedStatusUpdateResponse>;
1090
+ delete(params: FeedDeleteRequest): Promise<FeedDeleteResponse>;
1091
+ publish(params: FeedReleaseRequest): Promise<FeedReleaseResponse>;
1092
+ }
1093
+
1022
1094
  /** Playbook visibility states understood by the gateway. */
1023
1095
  type PlaybookVisibility = 'public' | 'private' | 'paid';
1024
1096
  interface SetVisibilityParams {
@@ -1473,6 +1545,25 @@ declare class SubscriptionsResource {
1473
1545
  unsubscribeBatch(params: UnsubscribeBatchParams): Promise<UnsubscribeBatchResponse>;
1474
1546
  }
1475
1547
 
1548
+ /**
1549
+ * Product-facing alert API. The current transport still calls the legacy
1550
+ * subscription and notification-history endpoints.
1551
+ */
1552
+ declare class AlertsResource {
1553
+ private client;
1554
+ constructor(client: AlvaClient);
1555
+ list(params?: PushSubscriptionListParams): Promise<PushSubscriptionListResponse>;
1556
+ enableAutomation(params: PushSubscriptionFeedParams): Promise<SubscribeFeedResponse>;
1557
+ disableAutomation(params: PushSubscriptionFeedParams): Promise<UnsubscribeResponse>;
1558
+ enablePlaybook(params: PushSubscriptionPlaybookParams): Promise<SubscribePlaybookResponse>;
1559
+ disablePlaybook(params: PushSubscriptionPlaybookParams): Promise<UnsubscribeResponse>;
1560
+ disableBatch(params: UnsubscribeBatchParams): Promise<UnsubscribeBatchResponse>;
1561
+ historyAutomation(params: NotificationListParams): Promise<FeedNotificationListResponse>;
1562
+ historyPlaybook(params: NotificationListParams): Promise<PlaybookNotificationListResponse>;
1563
+ preferences(): Promise<NotificationPreferencesResponse>;
1564
+ updatePreference(params: NotificationPreferenceUpdateParams): Promise<NotificationPreferenceUpdateResponse>;
1565
+ }
1566
+
1476
1567
  /**
1477
1568
  * Group push subscriptions for an external channel session.
1478
1569
  *
@@ -1640,6 +1731,7 @@ declare class AlvaClient {
1640
1731
  private _serviceAccount?;
1641
1732
  private _release?;
1642
1733
  private _feed?;
1734
+ private _automation?;
1643
1735
  private _playbooks?;
1644
1736
  private _secrets?;
1645
1737
  private _sdk?;
@@ -1655,6 +1747,7 @@ declare class AlvaClient {
1655
1747
  private _notifications?;
1656
1748
  private _notificationPreferences?;
1657
1749
  private _subscriptions?;
1750
+ private _alerts?;
1658
1751
  private _channelGroupSubscriptions?;
1659
1752
  private _feedback?;
1660
1753
  private _functions?;
@@ -1666,6 +1759,7 @@ declare class AlvaClient {
1666
1759
  get serviceAccount(): ServiceAccountResource;
1667
1760
  get release(): ReleaseResource;
1668
1761
  get feed(): FeedResource;
1762
+ get automation(): AutomationResource;
1669
1763
  get playbooks(): PlaybooksResource;
1670
1764
  get secrets(): SecretsResource;
1671
1765
  get sdk(): SdkDocsResource;
@@ -1681,6 +1775,7 @@ declare class AlvaClient {
1681
1775
  get notifications(): NotificationsResource;
1682
1776
  get notificationPreferences(): NotificationPreferencesResource;
1683
1777
  get subscriptions(): SubscriptionsResource;
1778
+ get alerts(): AlertsResource;
1684
1779
  get channelGroupSubscriptions(): ChannelGroupSubscriptionsResource;
1685
1780
  get feedback(): FeedbackResource;
1686
1781
  get functions(): FunctionsResource;
@@ -1833,4 +1928,4 @@ declare const installPlaybookRuntime: (targetWindow?: Window) => void;
1833
1928
  /** SDK version, injected at build time from package.json. */
1834
1929
  declare const VERSION: string;
1835
1930
 
1836
- export { AlvaClient, type AlvaClientConfig, AlvaError, type ChannelGroupAdminInfo, type ChannelGroupCallerInfo, type ChannelGroupSubscription, type ChannelGroupSubscriptionContextResponse, type ChannelGroupSubscriptionListResponse, type ChannelGroupSubscriptionMutationParams, type ChannelGroupSubscriptionMutationResponse, type ChannelGroupSubscriptionSessionParams, type ChannelGroupSubscriptionTarget, type ChannelGroupSubscriptionTargetType, CliUsageError, type CreateAllowanceParams, type CreateAllowanceResponse, type CreditAllowance, type CreditWallet, type CreditWalletItem, type CreditWalletItemConnection, type CreditWalletItemEdge, type CreditWalletItemsParams, type CreditWalletItemsResponse, type CreditWalletPageInfo, type DeleteFunctionParams, type FeedDeleteRequest, type FeedDeleteResponse, type FeedStatusUpdateRequest, type FeedStatusUpdateResponse, type FsChmodParams, type FsCopyParams, type FsEntry, type FsGrantParams, type FsMkdirParams, type FsRawWriteParams, type FsReadParams, type FsReaddirParams, type FsReaddirResponse, type FsReadlinkParams, type FsRemoveParams, type FsRenameParams, type FsRevokeParams, type FsStat, type FsSymlinkParams, type FsWriteParams, type FsWriteResponse, type GetAllowanceParams, type InvokeFunctionParams, type InvokeFunctionResponse, type ListAllowancesResponse, type ListFunctionsParams, type ListFunctionsResponse, type NotificationPreference, type NotificationPreferenceKey, type NotificationPreferenceUpdateParams, type NotificationPreferenceUpdateResponse, type NotificationPreferencesResponse, PBSV_UPDATE_MESSAGE, type PlaybookFunction, type PlaybookSkillFile, type PlaybookSkillFileMeta, type PlaybookSkillMeta, type PlaybookSkillSummary, type PlaybookSkillTagEntry, type RegisterFunctionParams, type RegisterFunctionResponse, type RevokeAllowanceParams, type RevokeAllowanceResponse, SUBSCRIBE_PROPOSE_MESSAGE, SUBSCRIBE_RESULT_MESSAGE, type SkillDoc, type SkillEndpointMetadata, type SkillEndpointTier, type SkillMetadata, type SkillSummary, type SubmitFeedbackRequest, type SubmitFeedbackResponse, type SubscribeApi, type SubscribeProposalInput, type SubscribeProposalResult, type TrendingPlaybookItem, type TrendingPlaybooksDir, type TrendingPlaybooksParams, type TrendingPlaybooksResponse, type TrendingPlaybooksSort, UDF_AUTH_REQUIRED_MESSAGE, UDF_CONSENT_REQUEST_MESSAGE, UDF_CONSENT_RESPONSE_MESSAGE, type UdfApi, UdfAuthRequiredError, type UdfButtonEventDetail, type UdfButtonOptions, UdfConsentDeniedError, UdfConsentRequiredError, UdfConsentTimeoutError, type UdfDescriptor, UdfError, UdfExecutionError, UdfFunctionDisabledError, UdfFunctionNotFoundError, UdfInsufficientCredits, type UdfInvokeResponse, UdfPidMismatchError, UdfRateLimitedError, UdfTokenExpiredError, UdfTokenInvalidError, UdfTransportError, VERSION, getViewerToken, installPlaybookRuntime, mapUdfErrorResponse, playbookIdFromToken, subscribe, udf };
1931
+ export { AlertsResource, AlvaClient, type AlvaClientConfig, AlvaError, AutomationResource, type ChannelGroupAdminInfo, type ChannelGroupCallerInfo, type ChannelGroupSubscription, type ChannelGroupSubscriptionContextResponse, type ChannelGroupSubscriptionListResponse, type ChannelGroupSubscriptionMutationParams, type ChannelGroupSubscriptionMutationResponse, type ChannelGroupSubscriptionSessionParams, type ChannelGroupSubscriptionTarget, type ChannelGroupSubscriptionTargetType, CliUsageError, type CreateAllowanceParams, type CreateAllowanceResponse, type CreditAllowance, type CreditWallet, type CreditWalletItem, type CreditWalletItemConnection, type CreditWalletItemEdge, type CreditWalletItemsParams, type CreditWalletItemsResponse, type CreditWalletPageInfo, type DeleteFunctionParams, type FeedDeleteRequest, type FeedDeleteResponse, type FeedListItem, type FeedListParams, type FeedListResponse, type FeedListStatus, type FeedStatusUpdateRequest, type FeedStatusUpdateResponse, type FsChmodParams, type FsCopyParams, type FsEntry, type FsGrantParams, type FsMkdirParams, type FsRawWriteParams, type FsReadParams, type FsReaddirParams, type FsReaddirResponse, type FsReadlinkParams, type FsRemoveParams, type FsRenameParams, type FsRevokeParams, type FsStat, type FsSymlinkParams, type FsWriteParams, type FsWriteResponse, type GetAllowanceParams, type InvokeFunctionParams, type InvokeFunctionResponse, type ListAllowancesResponse, type ListFunctionsParams, type ListFunctionsResponse, type NotificationPreference, type NotificationPreferenceKey, type NotificationPreferenceUpdateParams, type NotificationPreferenceUpdateResponse, type NotificationPreferencesResponse, PBSV_UPDATE_MESSAGE, type PlaybookFunction, type PlaybookSkillFile, type PlaybookSkillFileMeta, type PlaybookSkillMeta, type PlaybookSkillSummary, type PlaybookSkillTagEntry, type RegisterFunctionParams, type RegisterFunctionResponse, type RevokeAllowanceParams, type RevokeAllowanceResponse, SUBSCRIBE_PROPOSE_MESSAGE, SUBSCRIBE_RESULT_MESSAGE, type SkillDoc, type SkillEndpointMetadata, type SkillEndpointTier, type SkillMetadata, type SkillSummary, type SubmitFeedbackRequest, type SubmitFeedbackResponse, type SubscribeApi, type SubscribeProposalInput, type SubscribeProposalResult, type TrendingPlaybookItem, type TrendingPlaybooksDir, type TrendingPlaybooksParams, type TrendingPlaybooksResponse, type TrendingPlaybooksSort, UDF_AUTH_REQUIRED_MESSAGE, UDF_CONSENT_REQUEST_MESSAGE, UDF_CONSENT_RESPONSE_MESSAGE, type UdfApi, UdfAuthRequiredError, type UdfButtonEventDetail, type UdfButtonOptions, UdfConsentDeniedError, UdfConsentRequiredError, UdfConsentTimeoutError, type UdfDescriptor, UdfError, UdfExecutionError, UdfFunctionDisabledError, UdfFunctionNotFoundError, UdfInsufficientCredits, type UdfInvokeResponse, UdfPidMismatchError, UdfRateLimitedError, UdfTokenExpiredError, UdfTokenInvalidError, UdfTransportError, VERSION, getViewerToken, installPlaybookRuntime, mapUdfErrorResponse, playbookIdFromToken, subscribe, udf };
package/dist/index.js CHANGED
@@ -397,6 +397,19 @@ var FeedResource = class {
397
397
  this.client = client;
398
398
  }
399
399
  client;
400
+ /**
401
+ * List feeds owned by the caller. Backed by GET /api/v1/feed.
402
+ */
403
+ async list(params = {}) {
404
+ this.client._requireAuth();
405
+ return this.client._request("GET", "/api/v1/feed", {
406
+ query: {
407
+ limit: params.limit,
408
+ cursor: params.cursor,
409
+ status: params.status
410
+ }
411
+ });
412
+ }
400
413
  /**
401
414
  * Stop a feed's producer cronjob. This pauses future scheduled runs while
402
415
  * preserving the feed and its existing data.
@@ -448,6 +461,46 @@ function requireFeedID(id) {
448
461
  return id;
449
462
  }
450
463
 
464
+ // src/resources/automation.ts
465
+ var AutomationResource = class {
466
+ constructor(client) {
467
+ this.client = client;
468
+ }
469
+ client;
470
+ list(params = {}) {
471
+ return this.client.feed.list(params);
472
+ }
473
+ /**
474
+ * Inspect one automation. Backed by GET /api/v1/automation/:id.
475
+ */
476
+ async inspect(params) {
477
+ this.client._requireAuth();
478
+ const id = requireAutomationID(params.id);
479
+ return this.client._request(
480
+ "GET",
481
+ `/api/v1/automation/${encodeURIComponent(String(id))}`
482
+ );
483
+ }
484
+ stop(params) {
485
+ return this.client.feed.stop(params);
486
+ }
487
+ resume(params) {
488
+ return this.client.feed.resume(params);
489
+ }
490
+ delete(params) {
491
+ return this.client.feed.delete(params);
492
+ }
493
+ publish(params) {
494
+ return this.client.release.feed(params);
495
+ }
496
+ };
497
+ function requireAutomationID(id) {
498
+ if (!Number.isInteger(id) || id <= 0) {
499
+ throw new Error("automation id must be a positive integer");
500
+ }
501
+ return id;
502
+ }
503
+
451
504
  // src/resources/playbooks.ts
452
505
  var PLAYBOOK_VISIBILITIES = [
453
506
  "public",
@@ -2362,6 +2415,44 @@ var SubscriptionsResource = class {
2362
2415
  }
2363
2416
  };
2364
2417
 
2418
+ // src/resources/alerts.ts
2419
+ var AlertsResource = class {
2420
+ constructor(client) {
2421
+ this.client = client;
2422
+ }
2423
+ client;
2424
+ list(params = {}) {
2425
+ return this.client.subscriptions.list(params);
2426
+ }
2427
+ enableAutomation(params) {
2428
+ return this.client.subscriptions.subscribeFeed(params);
2429
+ }
2430
+ disableAutomation(params) {
2431
+ return this.client.subscriptions.unsubscribeFeed(params);
2432
+ }
2433
+ enablePlaybook(params) {
2434
+ return this.client.subscriptions.subscribePlaybook(params);
2435
+ }
2436
+ disablePlaybook(params) {
2437
+ return this.client.subscriptions.unsubscribePlaybook(params);
2438
+ }
2439
+ disableBatch(params) {
2440
+ return this.client.subscriptions.unsubscribeBatch(params);
2441
+ }
2442
+ historyAutomation(params) {
2443
+ return this.client.notifications.listFeed(params);
2444
+ }
2445
+ historyPlaybook(params) {
2446
+ return this.client.notifications.listPlaybook(params);
2447
+ }
2448
+ preferences() {
2449
+ return this.client.notificationPreferences.list();
2450
+ }
2451
+ updatePreference(params) {
2452
+ return this.client.notificationPreferences.update(params);
2453
+ }
2454
+ };
2455
+
2365
2456
  // src/resources/channelGroupSubscriptions.ts
2366
2457
  var ChannelGroupSubscriptionsResource = class {
2367
2458
  constructor(client) {
@@ -2794,6 +2885,7 @@ var AlvaClient = class {
2794
2885
  _serviceAccount;
2795
2886
  _release;
2796
2887
  _feed;
2888
+ _automation;
2797
2889
  _playbooks;
2798
2890
  _secrets;
2799
2891
  _sdk;
@@ -2809,6 +2901,7 @@ var AlvaClient = class {
2809
2901
  _notifications;
2810
2902
  _notificationPreferences;
2811
2903
  _subscriptions;
2904
+ _alerts;
2812
2905
  _channelGroupSubscriptions;
2813
2906
  _feedback;
2814
2907
  _functions;
@@ -2843,6 +2936,9 @@ var AlvaClient = class {
2843
2936
  get feed() {
2844
2937
  return this._feed ??= new FeedResource(this);
2845
2938
  }
2939
+ get automation() {
2940
+ return this._automation ??= new AutomationResource(this);
2941
+ }
2846
2942
  get playbooks() {
2847
2943
  return this._playbooks ??= new PlaybooksResource(this);
2848
2944
  }
@@ -2888,6 +2984,9 @@ var AlvaClient = class {
2888
2984
  get subscriptions() {
2889
2985
  return this._subscriptions ??= new SubscriptionsResource(this);
2890
2986
  }
2987
+ get alerts() {
2988
+ return this._alerts ??= new AlertsResource(this);
2989
+ }
2891
2990
  get channelGroupSubscriptions() {
2892
2991
  return this._channelGroupSubscriptions ??= new ChannelGroupSubscriptionsResource(this);
2893
2992
  }
@@ -3501,10 +3600,12 @@ var installPlaybookRuntime = (targetWindow) => {
3501
3600
  };
3502
3601
 
3503
3602
  // src/index.ts
3504
- var VERSION = true ? "0.15.0" : "dev";
3603
+ var VERSION = true ? "0.15.1-beta.0" : "dev";
3505
3604
  export {
3605
+ AlertsResource,
3506
3606
  AlvaClient,
3507
3607
  AlvaError,
3608
+ AutomationResource,
3508
3609
  CliUsageError,
3509
3610
  PBSV_UPDATE_MESSAGE,
3510
3611
  SUBSCRIBE_PROPOSE_MESSAGE,