@lessly/sdk-app 49.1.0 → 50.1.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.
Files changed (58) hide show
  1. package/dist/analytics/index.d.cts +1 -1
  2. package/dist/analytics/index.d.ts +1 -1
  3. package/dist/brain/index.cjs +5 -0
  4. package/dist/brain/index.cjs.map +1 -1
  5. package/dist/brain/index.d.cts +6 -2
  6. package/dist/brain/index.d.ts +6 -2
  7. package/dist/brain/index.js +5 -1
  8. package/dist/brain/index.js.map +1 -1
  9. package/dist/{client.gen-C39RGAWI.d.cts → client.gen-xvJrhIVe.d.cts} +94 -220
  10. package/dist/{client.gen-C39RGAWI.d.ts → client.gen-xvJrhIVe.d.ts} +94 -220
  11. package/dist/consent/index.d.cts +1 -1
  12. package/dist/consent/index.d.ts +1 -1
  13. package/dist/content/index.d.cts +1 -1
  14. package/dist/content/index.d.ts +1 -1
  15. package/dist/deployment/index.d.cts +1 -1
  16. package/dist/deployment/index.d.ts +1 -1
  17. package/dist/index.cjs +13 -104
  18. package/dist/index.cjs.map +1 -1
  19. package/dist/index.d.cts +83 -4
  20. package/dist/index.d.ts +83 -4
  21. package/dist/index.js +8545 -2
  22. package/dist/index.js.map +1 -1
  23. package/dist/mail/index.d.cts +2 -2
  24. package/dist/mail/index.d.ts +2 -2
  25. package/dist/observe/index.d.cts +1 -1
  26. package/dist/observe/index.d.ts +1 -1
  27. package/dist/organization/index.d.cts +1 -1
  28. package/dist/organization/index.d.ts +1 -1
  29. package/dist/realtime/index.d.cts +1 -1
  30. package/dist/realtime/index.d.ts +1 -1
  31. package/dist/support/index.d.cts +1 -1
  32. package/dist/support/index.d.ts +1 -1
  33. package/dist/tracking/index.d.cts +1 -1
  34. package/dist/tracking/index.d.ts +1 -1
  35. package/dist/users/index.d.cts +1 -1
  36. package/dist/users/index.d.ts +1 -1
  37. package/dist/waitlist/index.d.cts +1 -1
  38. package/dist/waitlist/index.d.ts +1 -1
  39. package/package.json +2 -7
  40. package/src/gen/bindings.gen.ts +14 -113
  41. package/src/gen/brain/index.ts +1 -1
  42. package/src/gen/brain/queryOptions.gen.ts +7 -0
  43. package/src/gen/client.gen.ts +5 -52
  44. package/src/gen/manifest.gen.ts +1 -1
  45. package/src/gen/types.gen.ts +92 -227
  46. package/dist/chunk-YVDZDXA7.js +0 -8648
  47. package/dist/chunk-YVDZDXA7.js.map +0 -1
  48. package/dist/playground/index.cjs +0 -81
  49. package/dist/playground/index.cjs.map +0 -1
  50. package/dist/playground/index.d.cts +0 -55
  51. package/dist/playground/index.d.ts +0 -55
  52. package/dist/playground/index.js +0 -58
  53. package/dist/playground/index.js.map +0 -1
  54. package/dist/types-gTIUAUsP.d.cts +0 -82
  55. package/dist/types-gTIUAUsP.d.ts +0 -82
  56. package/src/gen/playground/connect.gen.ts +0 -9
  57. package/src/gen/playground/index.ts +0 -4
  58. package/src/gen/playground/queryOptions.gen.ts +0 -86
@@ -82,6 +82,8 @@ import type {
82
82
  BrainProductSharedMemoryResetOutput,
83
83
  BrainRestoreStatusInput,
84
84
  BrainRestoreStatusOutput,
85
+ BrainUsageReportInput,
86
+ BrainUsageReportOutput,
85
87
  ConsentConfigCookieDomainUpsertInput,
86
88
  ConsentConfigCookieDomainUpsertOutput,
87
89
  ConsentConfigCustomizationUpsertInput,
@@ -702,30 +704,6 @@ import type {
702
704
  OrganizationSupportThreadReplyOutput,
703
705
  OrganizationSupportThreadsListInput,
704
706
  OrganizationSupportThreadsListOutput,
705
- PlaygroundAnalyticsOverviewInput,
706
- PlaygroundAnalyticsOverviewOutput,
707
- PlaygroundBillingEntitlementsInput,
708
- PlaygroundBillingEntitlementsOutput,
709
- PlaygroundBillingRecordUsageInput,
710
- PlaygroundBillingRecordUsageOutput,
711
- PlaygroundClickupCreateTaskInput,
712
- PlaygroundClickupCreateTaskOutput,
713
- PlaygroundClickupGetLastWebhookInput,
714
- PlaygroundClickupGetLastWebhookOutput,
715
- PlaygroundClickupGetOverviewInput,
716
- PlaygroundClickupGetOverviewOutput,
717
- PlaygroundGdriveGetLastChangeInput,
718
- PlaygroundGdriveGetLastChangeOutput,
719
- PlaygroundGdriveReadFileInput,
720
- PlaygroundGdriveReadFileOutput,
721
- PlaygroundGoogleadsReadCustomerInput,
722
- PlaygroundGoogleadsReadCustomerOutput,
723
- PlaygroundLifecycleGetStateInput,
724
- PlaygroundLifecycleGetStateOutput,
725
- PlaygroundLifecycleListEventsInput,
726
- PlaygroundLifecycleListEventsOutput,
727
- PlaygroundWebhookGetLastInput,
728
- PlaygroundWebhookGetLastOutput,
729
707
  RealtimeArchiveExportInput,
730
708
  RealtimeArchiveExportOutput,
731
709
  RealtimeArchiveExportStatusInput,
@@ -1133,6 +1111,9 @@ export interface GeneratedClient {
1133
1111
  restore: {
1134
1112
  status(input: BrainRestoreStatusInput): Promise<BrainRestoreStatusOutput>;
1135
1113
  };
1114
+ usage: {
1115
+ report(input: BrainUsageReportInput): Promise<BrainUsageReportOutput>;
1116
+ };
1136
1117
  };
1137
1118
  consent: {
1138
1119
  'config-cookie-domain': {
@@ -1672,34 +1653,6 @@ export interface GeneratedClient {
1672
1653
  list(input: OrganizationSupportThreadsListInput): Promise<OrganizationSupportThreadsListOutput>;
1673
1654
  };
1674
1655
  };
1675
- playground: {
1676
- analytics: {
1677
- overview(input: PlaygroundAnalyticsOverviewInput): Promise<PlaygroundAnalyticsOverviewOutput>;
1678
- };
1679
- billing: {
1680
- entitlements(input: PlaygroundBillingEntitlementsInput): Promise<PlaygroundBillingEntitlementsOutput>;
1681
- 'record-usage'(input: PlaygroundBillingRecordUsageInput): Promise<PlaygroundBillingRecordUsageOutput>;
1682
- };
1683
- clickup: {
1684
- 'create-task'(input: PlaygroundClickupCreateTaskInput): Promise<PlaygroundClickupCreateTaskOutput>;
1685
- 'get-last-webhook'(input: PlaygroundClickupGetLastWebhookInput): Promise<PlaygroundClickupGetLastWebhookOutput>;
1686
- 'get-overview'(input: PlaygroundClickupGetOverviewInput): Promise<PlaygroundClickupGetOverviewOutput>;
1687
- };
1688
- gdrive: {
1689
- 'get-last-change'(input: PlaygroundGdriveGetLastChangeInput): Promise<PlaygroundGdriveGetLastChangeOutput>;
1690
- 'read-file'(input: PlaygroundGdriveReadFileInput): Promise<PlaygroundGdriveReadFileOutput>;
1691
- };
1692
- googleads: {
1693
- 'read-customer'(input: PlaygroundGoogleadsReadCustomerInput): Promise<PlaygroundGoogleadsReadCustomerOutput>;
1694
- };
1695
- lifecycle: {
1696
- 'get-state'(input: PlaygroundLifecycleGetStateInput): Promise<PlaygroundLifecycleGetStateOutput>;
1697
- 'list-events'(input: PlaygroundLifecycleListEventsInput): Promise<PlaygroundLifecycleListEventsOutput>;
1698
- };
1699
- webhook: {
1700
- 'get-last'(input: PlaygroundWebhookGetLastInput): Promise<PlaygroundWebhookGetLastOutput>;
1701
- };
1702
- };
1703
1656
  realtime: {
1704
1657
  archive: {
1705
1658
  export(input: RealtimeArchiveExportInput): Promise<RealtimeArchiveExportOutput>;
@@ -1,2 +1,2 @@
1
1
  // AUTOGENERATED by scripts/generate.ts — do not edit.
2
- export const namespaces = ['analytics', 'brain', 'consent', 'content', 'deployment', 'mail', 'observe', 'organization', 'playground', 'realtime', 'support', 'tracking', 'users', 'waitlist'] as const;
2
+ export const namespaces = ['analytics', 'brain', 'consent', 'content', 'deployment', 'mail', 'observe', 'organization', 'realtime', 'support', 'tracking', 'users', 'waitlist'] as const;
@@ -1028,6 +1028,98 @@ snapshotId: string
1028
1028
  preRestoreSnapshotId: (string | null)
1029
1029
  } | null)
1030
1030
 
1031
+ export interface BrainUsageReportInput {
1032
+ /**
1033
+ * How many UTC days of this product's ledger to return, ending today (default 30, max 90)
1034
+ */
1035
+ days?: number
1036
+ }
1037
+
1038
+ export interface BrainUsageReportOutput {
1039
+ note: string
1040
+ /**
1041
+ * Brain's own ledger, for THIS product only
1042
+ */
1043
+ product: {
1044
+ /**
1045
+ * Inclusive UTC end of the window (today), YYYY-MM-DD
1046
+ */
1047
+ to: string
1048
+ /**
1049
+ * The window actually used, after clamping
1050
+ */
1051
+ days: number
1052
+ /**
1053
+ * Inclusive UTC start of the window, YYYY-MM-DD
1054
+ */
1055
+ from: string
1056
+ rows: {
1057
+ /**
1058
+ * 'sync' | 'batch'; '' when the push carried none
1059
+ */
1060
+ mode: string
1061
+ /**
1062
+ * Manifest meter slug, e.g. llm-tokens
1063
+ */
1064
+ meter: string
1065
+ /**
1066
+ * Model dimension; '' when the push carried none
1067
+ */
1068
+ model: string
1069
+ /**
1070
+ * How many record() calls landed in this slice
1071
+ */
1072
+ events: number
1073
+ /**
1074
+ * Tokens we metered for this slice, delivered or not
1075
+ */
1076
+ tokens: number
1077
+ /**
1078
+ * Purpose dimension; '' when the push carried none
1079
+ */
1080
+ purpose: string
1081
+ /**
1082
+ * UTC calendar day, YYYY-MM-DD
1083
+ */
1084
+ usage_date: string
1085
+ /**
1086
+ * Of those events, how many billing did not accept
1087
+ */
1088
+ delivery_failed: number
1089
+ }[]
1090
+ /**
1091
+ * The rows rolled up per meter across the whole window
1092
+ */
1093
+ totals: {
1094
+ meter: string
1095
+ events: number
1096
+ tokens: number
1097
+ delivery_failed: number
1098
+ }[]
1099
+ product_id: string
1100
+ }
1101
+ /**
1102
+ * The platform billing aggregate for the whole ORG; null if it could not be read
1103
+ */
1104
+ platform: ({
1105
+ plan: string
1106
+ scope: "org"
1107
+ meters: {
1108
+ unit?: string
1109
+ used?: number
1110
+ limit?: (number | null)
1111
+ remaining?: (number | null)
1112
+ unlimited?: boolean
1113
+ meter_slug: string
1114
+ }[]
1115
+ org_id: string
1116
+ } | null)
1117
+ /**
1118
+ * Why the platform aggregate is null; null when it was read successfully
1119
+ */
1120
+ platform_error: (string | null)
1121
+ }
1122
+
1031
1123
  export interface ConsentConfigCookieDomainUpsertInput {
1032
1124
  cookieDomain: ("" | null | string)
1033
1125
  }
@@ -19367,7 +19459,6 @@ displayName: (string | null)
19367
19459
  orgRoles: {
19368
19460
  id: string
19369
19461
  name: string
19370
- description: (string | null)
19371
19462
  }[]
19372
19463
  canManage: boolean
19373
19464
  inherited: {
@@ -19764,232 +19855,6 @@ lastMessagePreview: (string | null)
19764
19855
  }[]
19765
19856
  }
19766
19857
 
19767
- export interface PlaygroundAnalyticsOverviewInput {
19768
- /**
19769
- * Max records per entity in recent[]; omit for the endpoint default
19770
- */
19771
- limit?: number
19772
- }
19773
-
19774
- export interface PlaygroundAnalyticsOverviewOutput {
19775
- ok: boolean
19776
- minted: boolean
19777
- overview?: unknown
19778
- http_status: number
19779
- }
19780
-
19781
- export interface PlaygroundBillingEntitlementsInput {
19782
-
19783
- }
19784
-
19785
- export interface PlaygroundBillingEntitlementsOutput {
19786
- ok: boolean
19787
- minted: boolean
19788
- http_status: number
19789
- entitlements?: unknown
19790
- }
19791
-
19792
- export interface PlaygroundBillingRecordUsageInput {
19793
- /**
19794
- * Quantity of events to record against playground-events (SUM); defaults to 1
19795
- */
19796
- value?: number
19797
- }
19798
-
19799
- export interface PlaygroundBillingRecordUsageOutput {
19800
- minted: boolean
19801
- accepted: (number | null)
19802
- recorded: boolean
19803
- duplicates: (number | null)
19804
- http_status: number
19805
- }
19806
-
19807
- export interface PlaygroundClickupCreateTaskInput {
19808
- /**
19809
- * Task title; defaults to a fixture label
19810
- */
19811
- name?: string
19812
- /**
19813
- * ClickUp list id; falls back to CLICKUP_TEST_LIST_ID
19814
- */
19815
- listId?: string
19816
- }
19817
-
19818
- export interface PlaygroundClickupCreateTaskOutput {
19819
- minted: boolean
19820
- task_id: (string | null)
19821
- list_status: number
19822
- vend_status: number
19823
- clickup_status: number
19824
- installation_count: number
19825
- }
19826
-
19827
- export interface PlaygroundClickupGetLastWebhookInput {
19828
-
19829
- }
19830
-
19831
- export type PlaygroundClickupGetLastWebhookOutput = ({
19832
- payload: string
19833
- event_id: string
19834
- provider: string
19835
- verified: boolean
19836
- product_id: string
19837
- occurred_at: string
19838
- connector_id: string
19839
- clickup_event: (string | null)
19840
- receipt_count: number
19841
- } | {
19842
- found: false
19843
- })
19844
-
19845
- export interface PlaygroundClickupGetOverviewInput {
19846
-
19847
- }
19848
-
19849
- export interface PlaygroundClickupGetOverviewOutput {
19850
- team: ({
19851
- teamId: string
19852
- teamName: string
19853
- } | null)
19854
- lists: PlaygroundClickupGetOverviewOutputItems[]
19855
- tasks: {
19856
- id: string
19857
- name: string
19858
- status: (string | null)
19859
- }[]
19860
- minted: boolean
19861
- spaces: PlaygroundClickupGetOverviewOutputItems[]
19862
- list_status: number
19863
- vend_status: number
19864
- lists_status: number
19865
- tasks_status: number
19866
- spaces_status: number
19867
- folders_status: number
19868
- installation_count: number
19869
- }
19870
- export interface PlaygroundClickupGetOverviewOutputItems {
19871
- id: string
19872
- name: string
19873
- }
19874
-
19875
- export interface PlaygroundGdriveGetLastChangeInput {
19876
-
19877
- }
19878
-
19879
- export type PlaygroundGdriveGetLastChangeOutput = ({
19880
- file_id: string
19881
- removed: boolean
19882
- file_name: (string | null)
19883
- mime_type: (string | null)
19884
- product_id: string
19885
- occurred_at: string
19886
- connector_id: string
19887
- resource_state: string
19888
- } | {
19889
- found: false
19890
- })
19891
-
19892
- export interface PlaygroundGdriveReadFileInput {
19893
- /**
19894
- * Drive file id; falls back to GDRIVE_TEST_FILE_ID, then the first picked file
19895
- */
19896
- fileId?: string
19897
- }
19898
-
19899
- export interface PlaygroundGdriveReadFileOutput {
19900
- minted: boolean
19901
- file_id: (string | null)
19902
- file_name: (string | null)
19903
- mime_type: (string | null)
19904
- file_count: number
19905
- get_status: number
19906
- list_status: number
19907
- vend_status: number
19908
- content_bytes: (number | null)
19909
- }
19910
-
19911
- export interface PlaygroundGoogleadsReadCustomerInput {
19912
-
19913
- }
19914
-
19915
- export interface PlaygroundGoogleadsReadCustomerOutput {
19916
- minted: boolean
19917
- vended: boolean
19918
- customer_id: (string | null)
19919
- vend_status: number
19920
- result_count: number
19921
- search_status: number
19922
- login_customer_id: (string | null)
19923
- }
19924
-
19925
- export interface PlaygroundLifecycleGetStateInput {
19926
-
19927
- }
19928
-
19929
- export interface PlaygroundLifecycleGetStateOutput {
19930
- blocked: boolean
19931
- archived: boolean
19932
- productId: string
19933
- lastBlockTransition: ({
19934
- eventId: string
19935
- eventName: string
19936
- productId: string
19937
- occurredAt: string
19938
- recordedAt: string
19939
- receiptCount: number
19940
- organizationId: string
19941
- cascadedFromOrg: boolean
19942
- } | null)
19943
- lastArchiveTransition: ({
19944
- eventId: string
19945
- eventName: string
19946
- productId: string
19947
- occurredAt: string
19948
- recordedAt: string
19949
- receiptCount: number
19950
- organizationId: string
19951
- cascadedFromOrg: boolean
19952
- } | null)
19953
- }
19954
-
19955
- export interface PlaygroundLifecycleListEventsInput {
19956
-
19957
- }
19958
-
19959
- export type PlaygroundLifecycleListEventsOutput = {
19960
- eventId: string
19961
- eventName: string
19962
- productId: string
19963
- occurredAt: string
19964
- recordedAt: string
19965
- receiptCount: number
19966
- organizationId: string
19967
- cascadedFromOrg: boolean
19968
- }[]
19969
-
19970
- export interface PlaygroundWebhookGetLastInput {
19971
-
19972
- }
19973
-
19974
- export type PlaygroundWebhookGetLastOutput = ({
19975
- payload?: unknown
19976
- event_id: string
19977
- provider: string
19978
- verified: boolean
19979
- product_id: string
19980
- occurred_at: string
19981
- connector_id: string
19982
- delivery_count: number
19983
- } | {
19984
- found: false
19985
- })
19986
-
19987
- export interface PlaygroundWsEchoInput {
19988
-
19989
- }
19990
-
19991
- export type PlaygroundWsEchoOutput = unknown;
19992
-
19993
19858
  export interface RealtimeArchiveExportInput {
19994
19859
  /**
19995
19860
  * Only entries with ts <= to_ts (epoch ms)