samva 0.15.0 → 0.17.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 (128) hide show
  1. package/AGENTS.md +4 -1
  2. package/README.md +46 -1
  3. package/dist/analytics-CaqPRsry.js +207 -0
  4. package/dist/api-keys-Ce1Y4_Ip.js +274 -0
  5. package/dist/attachments-DYqVIraC.js +140 -0
  6. package/dist/brands-ZwuOGIWO.js +175 -0
  7. package/dist/campaigns-DZlz1E9E.js +522 -0
  8. package/dist/categories-CA4XIQAb.js +1011 -0
  9. package/dist/client/sdk.gen.d.ts +234 -49
  10. package/dist/client/types.gen.d.ts +1521 -348
  11. package/dist/client-DOzUrdTE.js +1115 -0
  12. package/dist/contact-groups-BLbFXnjq.js +446 -0
  13. package/dist/contacts-BbsoXXB4.js +787 -0
  14. package/dist/conversations-_sRHueML.js +494 -0
  15. package/dist/custom-fields-BHWbwlKn.js +176 -0
  16. package/dist/effect/analytics.js +2 -21
  17. package/dist/effect/api-keys.d.ts +1 -0
  18. package/dist/effect/api-keys.js +2 -25
  19. package/dist/effect/attachments.js +2 -17
  20. package/dist/effect/brands.d.ts +1 -1
  21. package/dist/effect/brands.js +3 -24
  22. package/dist/effect/campaigns.js +2 -33
  23. package/dist/effect/categories.js +1 -1
  24. package/dist/effect/client.d.ts +1 -1
  25. package/dist/effect/client.js +3 -4
  26. package/dist/effect/contact-groups.js +2 -29
  27. package/dist/effect/contacts.d.ts +52 -0
  28. package/dist/effect/contacts.js +2 -47
  29. package/dist/effect/conversations.js +2 -35
  30. package/dist/effect/custom-fields.js +2 -17
  31. package/dist/effect/email.d.ts +3 -20
  32. package/dist/effect/email.js +2 -141
  33. package/dist/effect/events.d.ts +121 -0
  34. package/dist/effect/events.js +3 -0
  35. package/dist/effect/extension-installations.js +2 -27
  36. package/dist/effect/extensions.js +2 -19
  37. package/dist/effect/feedback.d.ts +1 -1
  38. package/dist/effect/feedback.js +3 -13
  39. package/dist/effect/generated/analytics.d.ts +715 -0
  40. package/dist/effect/generated/api-keys.d.ts +1627 -0
  41. package/dist/effect/generated/attachments.d.ts +554 -0
  42. package/dist/effect/generated/brands.d.ts +1118 -0
  43. package/dist/effect/generated/campaigns.d.ts +3783 -0
  44. package/dist/effect/generated/contact-events.d.ts +158 -0
  45. package/dist/effect/generated/contact-groups.d.ts +1445 -0
  46. package/dist/effect/generated/contacts.d.ts +3789 -0
  47. package/dist/effect/generated/conversations.d.ts +2870 -0
  48. package/dist/effect/generated/custom-fields.d.ts +562 -0
  49. package/dist/effect/generated/email.d.ts +10622 -0
  50. package/dist/effect/generated/events.d.ts +463 -0
  51. package/dist/effect/generated/extension-installations.d.ts +1786 -0
  52. package/dist/effect/generated/extensions.d.ts +927 -0
  53. package/dist/effect/generated/feedback.d.ts +116 -0
  54. package/dist/effect/generated/index.d.ts +61 -0
  55. package/dist/effect/generated/journeys.d.ts +6135 -0
  56. package/dist/effect/generated/mailboxes.d.ts +13641 -0
  57. package/dist/effect/generated/media.d.ts +741 -0
  58. package/dist/effect/generated/messages.d.ts +2355 -0
  59. package/dist/effect/generated/namespaces.d.ts +654 -0
  60. package/dist/effect/generated/operations.d.ts +514 -0
  61. package/dist/effect/generated/organizations.d.ts +1111 -0
  62. package/dist/effect/generated/scheduled-messages.d.ts +1798 -0
  63. package/dist/effect/generated/shared.d.ts +3250 -0
  64. package/dist/effect/generated/subscriptions.d.ts +188 -0
  65. package/dist/effect/generated/templates.d.ts +8177 -0
  66. package/dist/effect/generated/unsubscribe-groups.d.ts +1153 -0
  67. package/dist/effect/generated/webhooks.d.ts +1697 -0
  68. package/dist/effect/generated/whoami.d.ts +291 -0
  69. package/dist/effect/generated-metadata.d.ts +1631 -0
  70. package/dist/effect/index.d.ts +4 -1
  71. package/dist/effect/index.js +29 -26
  72. package/dist/effect/internal/client.d.ts +10 -7
  73. package/dist/effect/internal/email-sender.d.ts +17 -0
  74. package/dist/effect/internal/operation.d.ts +12 -72
  75. package/dist/effect/internal/send.d.ts +60 -0
  76. package/dist/effect/journeys.d.ts +2153 -0
  77. package/dist/effect/journeys.js +2 -0
  78. package/dist/effect/mailboxes.d.ts +255 -205
  79. package/dist/effect/mailboxes.js +2 -2
  80. package/dist/effect/media.js +3 -1
  81. package/dist/effect/messages.d.ts +2 -2
  82. package/dist/effect/messages.js +3 -1
  83. package/dist/effect/namespaces.js +2 -19
  84. package/dist/effect/operations.js +2 -15
  85. package/dist/effect/organizations.js +2 -23
  86. package/dist/effect/retry.js +1 -1
  87. package/dist/effect/scheduled-messages.js +2 -19
  88. package/dist/effect/subscriptions.js +2 -9
  89. package/dist/effect/templates.d.ts +1 -1
  90. package/dist/effect/templates.js +3 -78
  91. package/dist/effect/unsubscribe-groups.js +2 -27
  92. package/dist/effect/webhooks.d.ts +9 -9
  93. package/dist/effect/webhooks.js +3 -33
  94. package/dist/effect/whoami.d.ts +46 -0
  95. package/dist/effect/whoami.js +2 -0
  96. package/dist/email-R0NAA9PW.js +2498 -0
  97. package/dist/events-CxbTUHYT.js +82 -0
  98. package/dist/extension-installations-CD94LPmk.js +407 -0
  99. package/dist/extensions-BKyNQLvu.js +220 -0
  100. package/dist/feedback-Bpa09JOS.js +52 -0
  101. package/dist/index.js +3 -3
  102. package/dist/{inline-attachments-UxLeyytJ.js → inline-attachments-Bi1hDltp.js} +2 -2
  103. package/dist/journeys-CARo_BJT.js +499 -0
  104. package/dist/mailboxes-BRDn7BIK.js +2470 -0
  105. package/dist/media-VrrtNnft.js +181 -0
  106. package/dist/namespaces-CcvEbG-y.js +152 -0
  107. package/dist/{operation-BZ5Xov-x.js → operation-n_IYgNVK.js} +85 -102
  108. package/dist/operations-CmB3FHwf.js +93 -0
  109. package/dist/organizations-A-plufWc.js +252 -0
  110. package/dist/promises/errors.gen.d.ts +12 -2
  111. package/dist/promises/index.d.ts +9 -3
  112. package/dist/promises/index.js +3 -3
  113. package/dist/promises/types.gen.d.ts +1 -1
  114. package/dist/{promises-Cd6Jamqk.js → promises---Kbh-7z.js} +745 -195
  115. package/dist/runtime-P0l1_2-C.js +25 -0
  116. package/dist/scheduled-messages-DkKZRRaN.js +207 -0
  117. package/dist/send-Bxc0XfGE.js +722 -0
  118. package/dist/service-map.d.ts +101 -15
  119. package/dist/subscriptions-DEXYtMXg.js +67 -0
  120. package/dist/templates-DZomxsG7.js +2289 -0
  121. package/dist/unsubscribe-groups-Iqk4Isf9.js +291 -0
  122. package/dist/webhooks-CPXuu8Xf.js +530 -0
  123. package/dist/whoami-Ccz0jwlt.js +59 -0
  124. package/package.json +17 -3
  125. package/dist/categories-BGUBFdH9.js +0 -183
  126. package/dist/client-CDg7zJs0.js +0 -13726
  127. package/dist/effect/generated.d.ts +0 -64059
  128. package/dist/mailboxes-BH_JPmOE.js +0 -159
@@ -0,0 +1,116 @@
1
+ import type * as EffectBrand from "effect/Brand";
2
+ import { HttpApiEndpoint, HttpApiGroup } from "effect/http-api";
3
+ import * as Schema from "effect/Schema";
4
+ import { ApiKeySecurityMiddleware, FeedbackContext, ForbiddenError, GatewayTimeoutError, InternalError, UnauthorizedError, ValidationError } from "./shared";
5
+ export type FeedbackId = string & EffectBrand.Brand<"FeedbackId">;
6
+ export declare const FeedbackId: Schema.brand<Schema.String, "FeedbackId">;
7
+ export type FeedbackReceipt = {
8
+ readonly id: FeedbackId;
9
+ readonly createdAt: string;
10
+ };
11
+ export declare const FeedbackReceipt: Schema.Struct<{
12
+ readonly id: Schema.brand<Schema.String, "FeedbackId">;
13
+ readonly createdAt: Schema.String;
14
+ }>;
15
+ export type FeedbackSendRequestJson = {
16
+ readonly message: string;
17
+ readonly category?: "bug" | "confusing" | "missing" | "other" | null;
18
+ readonly context?: FeedbackContext | null;
19
+ };
20
+ export declare const FeedbackSendRequestJson: Schema.Struct<{
21
+ readonly message: Schema.String;
22
+ readonly category: Schema.optionalKey<Schema.Union<readonly [Schema.Union<readonly [Schema.Literal<"bug">, Schema.Literal<"confusing">, Schema.Literal<"missing">, Schema.Literal<"other">]>, Schema.Null]>>;
23
+ readonly context: Schema.optionalKey<Schema.Union<readonly [Schema.Struct<{
24
+ readonly operation: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
25
+ readonly resourceId: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
26
+ }>, Schema.Null]>>;
27
+ }>;
28
+ export type FeedbackSend201 = FeedbackReceipt;
29
+ export declare const FeedbackSend201: Schema.Struct<{
30
+ readonly id: Schema.brand<Schema.String, "FeedbackId">;
31
+ readonly createdAt: Schema.String;
32
+ }>;
33
+ export type FeedbackSend401 = UnauthorizedError;
34
+ export declare const FeedbackSend401: typeof UnauthorizedError;
35
+ export type FeedbackSend403 = ForbiddenError;
36
+ export declare const FeedbackSend403: typeof ForbiddenError;
37
+ export type FeedbackSend422 = ValidationError;
38
+ export declare const FeedbackSend422: typeof ValidationError;
39
+ export type FeedbackSend500 = InternalError;
40
+ export declare const FeedbackSend500: typeof InternalError;
41
+ export type FeedbackSend504 = GatewayTimeoutError;
42
+ export declare const FeedbackSend504: typeof GatewayTimeoutError;
43
+ declare const FeedbackGroup_base: HttpApiGroup.HttpApiGroup<"Feedback", HttpApiEndpoint.HttpApiEndpoint<"feedbackSend", "POST", "/v1/feedback", never, never, Schema.toCodecJson<Schema.Struct<{
44
+ readonly message: Schema.String;
45
+ readonly category: Schema.optionalKey<Schema.Union<readonly [Schema.Union<readonly [Schema.Literal<"bug">, Schema.Literal<"confusing">, Schema.Literal<"missing">, Schema.Literal<"other">]>, Schema.Null]>>;
46
+ readonly context: Schema.optionalKey<Schema.Union<readonly [Schema.Struct<{
47
+ readonly operation: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
48
+ readonly resourceId: Schema.optionalKey<Schema.Union<readonly [Schema.String, Schema.Null]>>;
49
+ }>, Schema.Null]>>;
50
+ }>>, never, Schema.toCodecJson<Schema.Struct<{
51
+ readonly id: Schema.brand<Schema.String, "FeedbackId">;
52
+ readonly createdAt: Schema.String;
53
+ }>>, Schema.toCodecJson<Schema.decodeTo<Schema.declareConstructor<ForbiddenError, {
54
+ readonly _tag: "ForbiddenError";
55
+ readonly message: string;
56
+ }, readonly [Schema.Struct<{
57
+ readonly _tag: Schema.tag<"ForbiddenError">;
58
+ readonly message: Schema.String;
59
+ }>], {
60
+ readonly _tag: "ForbiddenError";
61
+ readonly message: string;
62
+ }>, Schema.Struct<{
63
+ readonly _tag: Schema.tag<"ForbiddenError">;
64
+ readonly message: Schema.String;
65
+ }>, never, never> | Schema.decodeTo<Schema.declareConstructor<GatewayTimeoutError, {
66
+ readonly _tag: "GatewayTimeoutError";
67
+ readonly message: string;
68
+ readonly retryAfterSeconds: number;
69
+ }, readonly [Schema.Struct<{
70
+ readonly _tag: Schema.tag<"GatewayTimeoutError">;
71
+ readonly message: Schema.String;
72
+ readonly retryAfterSeconds: Schema.Finite;
73
+ }>], {
74
+ readonly _tag: "GatewayTimeoutError";
75
+ readonly message: string;
76
+ readonly retryAfterSeconds: number;
77
+ }>, Schema.Struct<{
78
+ readonly _tag: Schema.tag<"GatewayTimeoutError">;
79
+ readonly message: Schema.String;
80
+ readonly retryAfterSeconds: Schema.Finite;
81
+ }>, never, never> | Schema.decodeTo<Schema.declareConstructor<UnauthorizedError, {
82
+ readonly _tag: "UnauthorizedError";
83
+ readonly message: string;
84
+ }, readonly [Schema.Struct<{
85
+ readonly _tag: Schema.tag<"UnauthorizedError">;
86
+ readonly message: Schema.String;
87
+ }>], {
88
+ readonly _tag: "UnauthorizedError";
89
+ readonly message: string;
90
+ }>, Schema.Struct<{
91
+ readonly _tag: Schema.tag<"UnauthorizedError">;
92
+ readonly message: Schema.String;
93
+ }>, never, never> | Schema.decodeTo<Schema.declareConstructor<ValidationError, {
94
+ readonly _tag: "ValidationError";
95
+ readonly message: string;
96
+ readonly fields?: {
97
+ readonly [x: string]: readonly string[];
98
+ } | null;
99
+ }, readonly [Schema.Struct<{
100
+ readonly _tag: Schema.tag<"ValidationError">;
101
+ readonly message: Schema.String;
102
+ readonly fields: Schema.optionalKey<Schema.Union<readonly [Schema.$Record<Schema.String, Schema.$Array<Schema.String>>, Schema.Null]>>;
103
+ }>], {
104
+ readonly _tag: "ValidationError";
105
+ readonly message: string;
106
+ readonly fields?: {
107
+ readonly [x: string]: readonly string[];
108
+ } | null;
109
+ }>, Schema.Struct<{
110
+ readonly _tag: Schema.tag<"ValidationError">;
111
+ readonly message: Schema.String;
112
+ readonly fields: Schema.optionalKey<Schema.Union<readonly [Schema.$Record<Schema.String, Schema.$Array<Schema.String>>, Schema.Null]>>;
113
+ }>, never, never> | typeof InternalError>, ApiKeySecurityMiddleware, never>, false>;
114
+ export declare class FeedbackGroup extends FeedbackGroup_base {
115
+ }
116
+ export {};
@@ -0,0 +1,61 @@
1
+ import { HttpApi } from "effect/http-api";
2
+ import { AnalyticsGroup } from "./analytics";
3
+ import { APIKeysGroup } from "./api-keys";
4
+ import { AttachmentsGroup } from "./attachments";
5
+ import { BrandsGroup } from "./brands";
6
+ import { CampaignsGroup } from "./campaigns";
7
+ import { ContactEventsGroup } from "./contact-events";
8
+ import { ContactGroupsGroup } from "./contact-groups";
9
+ import { ContactsGroup } from "./contacts";
10
+ import { ConversationsGroup } from "./conversations";
11
+ import { CustomFieldsGroup } from "./custom-fields";
12
+ import { EmailGroup } from "./email";
13
+ import { EventsGroup } from "./events";
14
+ import { ExtensionInstallationsGroup } from "./extension-installations";
15
+ import { ExtensionsGroup } from "./extensions";
16
+ import { FeedbackGroup } from "./feedback";
17
+ import { JourneysGroup } from "./journeys";
18
+ import { MailboxesGroup } from "./mailboxes";
19
+ import { MediaGroup } from "./media";
20
+ import { MessagesGroup } from "./messages";
21
+ import { NamespacesGroup } from "./namespaces";
22
+ import { OperationsGroup } from "./operations";
23
+ import { OrganizationsGroup } from "./organizations";
24
+ import { ScheduledMessagesGroup } from "./scheduled-messages";
25
+ import { SubscriptionsGroup } from "./subscriptions";
26
+ import { TemplatesGroup } from "./templates";
27
+ import { UnsubscribeGroupsGroup } from "./unsubscribe-groups";
28
+ import { WebhooksGroup } from "./webhooks";
29
+ import { WhoamiGroup } from "./whoami";
30
+ export * from "./shared";
31
+ export * from "./analytics";
32
+ export * from "./api-keys";
33
+ export * from "./attachments";
34
+ export * from "./brands";
35
+ export * from "./campaigns";
36
+ export * from "./contact-groups";
37
+ export * from "./contacts";
38
+ export * from "./contact-events";
39
+ export * from "./conversations";
40
+ export * from "./custom-fields";
41
+ export * from "./email";
42
+ export * from "./events";
43
+ export * from "./extension-installations";
44
+ export * from "./extensions";
45
+ export * from "./feedback";
46
+ export * from "./journeys";
47
+ export * from "./mailboxes";
48
+ export * from "./media";
49
+ export * from "./messages";
50
+ export * from "./scheduled-messages";
51
+ export * from "./namespaces";
52
+ export * from "./operations";
53
+ export * from "./organizations";
54
+ export * from "./subscriptions";
55
+ export * from "./templates";
56
+ export * from "./unsubscribe-groups";
57
+ export * from "./webhooks";
58
+ export * from "./whoami";
59
+ declare const SamvaApi_base: HttpApi.HttpApi<"SamvaApi", typeof AnalyticsGroup | typeof APIKeysGroup | typeof AttachmentsGroup | typeof BrandsGroup | typeof CampaignsGroup | typeof ContactEventsGroup | typeof ContactGroupsGroup | typeof ContactsGroup | typeof ConversationsGroup | typeof CustomFieldsGroup | typeof EmailGroup | typeof EventsGroup | typeof ExtensionInstallationsGroup | typeof ExtensionsGroup | typeof FeedbackGroup | typeof JourneysGroup | typeof MailboxesGroup | typeof MediaGroup | typeof MessagesGroup | typeof NamespacesGroup | typeof OperationsGroup | typeof OrganizationsGroup | typeof ScheduledMessagesGroup | typeof SubscriptionsGroup | typeof TemplatesGroup | typeof UnsubscribeGroupsGroup | typeof WebhooksGroup | typeof WhoamiGroup>;
60
+ export declare class SamvaApi extends SamvaApi_base {
61
+ }