@marcoappio/marco-config 2.0.415 → 2.0.417

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 (126) hide show
  1. package/dist/index.d.ts +3 -4
  2. package/dist/index.d.ts.map +1 -1
  3. package/dist/index.js +3 -3
  4. package/dist/marcoPublicConfig.d.ts +9 -1
  5. package/dist/marcoPublicConfig.d.ts.map +1 -1
  6. package/dist/marcoPublicConfig.js +12 -0
  7. package/dist/schemas/app.d.ts +1 -1
  8. package/dist/schemas/app.d.ts.map +1 -1
  9. package/dist/schemas/app.js +2 -1
  10. package/dist/schemas/emailAccount.d.ts +1 -1
  11. package/dist/schemas/index.d.ts +3 -3
  12. package/dist/schemas/oauth.d.ts +1 -1
  13. package/dist/schemas/oauth.d.ts.map +1 -1
  14. package/dist/schemas/oauth.js +2 -1
  15. package/dist/sdk/endpoints/index.d.ts +0 -887
  16. package/dist/sdk/endpoints/index.d.ts.map +1 -1
  17. package/dist/sdk/endpoints/private/index.d.ts +0 -887
  18. package/dist/sdk/endpoints/private/index.d.ts.map +1 -1
  19. package/dist/sdk/endpoints/private/index.js +0 -2
  20. package/dist/sdk/index.d.ts +0 -887
  21. package/dist/sdk/index.d.ts.map +1 -1
  22. package/dist/types/MarcoPlatform.d.ts +3 -0
  23. package/dist/types/MarcoPlatform.d.ts.map +1 -0
  24. package/dist/types/MarcoPlatform.js +1 -0
  25. package/dist/types/OAuthProvider.d.ts +3 -0
  26. package/dist/types/OAuthProvider.d.ts.map +1 -0
  27. package/dist/types/OAuthProvider.js +1 -0
  28. package/dist/types/index.d.ts +2 -2
  29. package/dist/types/index.d.ts.map +1 -1
  30. package/dist/types/index.js +2 -2
  31. package/dist/utils/index.d.ts +1 -0
  32. package/dist/utils/index.d.ts.map +1 -1
  33. package/dist/utils/index.js +1 -0
  34. package/dist/utils/labels/index.d.ts +4 -0
  35. package/dist/utils/labels/index.d.ts.map +1 -0
  36. package/dist/utils/labels/index.js +4 -0
  37. package/dist/zero/index.d.ts +1448 -0
  38. package/dist/zero/index.d.ts.map +1 -0
  39. package/dist/zero/index.js +13 -0
  40. package/dist/{sdk/endpoints/private/sync/push → zero/mutators}/account.d.ts +33 -75
  41. package/dist/zero/mutators/account.d.ts.map +1 -0
  42. package/dist/zero/mutators/account.js +69 -0
  43. package/dist/{sdk/endpoints/private/sync/push → zero/mutators}/draft.d.ts +35 -79
  44. package/dist/{clients → zero/mutators}/draft.d.ts.map +1 -1
  45. package/dist/zero/mutators/draft.js +114 -0
  46. package/dist/{sdk/endpoints/private/sync/push → zero/mutators}/thread.d.ts +32 -76
  47. package/dist/zero/mutators/thread.d.ts.map +1 -0
  48. package/dist/zero/mutators/thread.js +76 -0
  49. package/dist/zero/mutators/user.d.ts +32 -0
  50. package/dist/zero/mutators/user.d.ts.map +1 -0
  51. package/dist/zero/mutators/user.js +33 -0
  52. package/dist/zero/mutators.d.ts +412 -0
  53. package/dist/zero/mutators.d.ts.map +1 -0
  54. package/dist/zero/mutators.js +44 -0
  55. package/dist/zero/mutators.test.d.ts +2 -0
  56. package/dist/zero/mutators.test.d.ts.map +1 -0
  57. package/dist/zero/mutators.test.js +33 -0
  58. package/dist/zero/schema.d.ts +1438 -0
  59. package/dist/zero/schema.d.ts.map +1 -0
  60. package/dist/zero/schema.js +430 -0
  61. package/package.json +2 -1
  62. package/dist/clients/account.d.ts +0 -144
  63. package/dist/clients/account.d.ts.map +0 -1
  64. package/dist/clients/account.js +0 -93
  65. package/dist/clients/contact.d.ts +0 -14
  66. package/dist/clients/contact.d.ts.map +0 -1
  67. package/dist/clients/contact.js +0 -14
  68. package/dist/clients/draft.d.ts +0 -196
  69. package/dist/clients/draft.js +0 -122
  70. package/dist/clients/index.d.ts +0 -526
  71. package/dist/clients/index.d.ts.map +0 -1
  72. package/dist/clients/index.js +0 -13
  73. package/dist/clients/thread.d.ts +0 -125
  74. package/dist/clients/thread.d.ts.map +0 -1
  75. package/dist/clients/thread.js +0 -117
  76. package/dist/clients/user.d.ts +0 -53
  77. package/dist/clients/user.d.ts.map +0 -1
  78. package/dist/clients/user.js +0 -52
  79. package/dist/clients/utils/index.d.ts +0 -4
  80. package/dist/clients/utils/index.d.ts.map +0 -1
  81. package/dist/clients/utils/index.js +0 -4
  82. package/dist/clients/utils/labelSpecialUseOrdering.d.ts +0 -3
  83. package/dist/clients/utils/labelSpecialUseOrdering.d.ts.map +0 -1
  84. package/dist/clients/utils/labelSpecialUseOrdering.js +0 -1
  85. package/dist/sdk/endpoints/private/sync/index.d.ts +0 -888
  86. package/dist/sdk/endpoints/private/sync/index.d.ts.map +0 -1
  87. package/dist/sdk/endpoints/private/sync/index.js +0 -3
  88. package/dist/sdk/endpoints/private/sync/pull/account.d.ts +0 -71
  89. package/dist/sdk/endpoints/private/sync/pull/account.d.ts.map +0 -1
  90. package/dist/sdk/endpoints/private/sync/pull/account.js +0 -33
  91. package/dist/sdk/endpoints/private/sync/pull/contact.d.ts +0 -56
  92. package/dist/sdk/endpoints/private/sync/pull/contact.d.ts.map +0 -1
  93. package/dist/sdk/endpoints/private/sync/pull/contact.js +0 -40
  94. package/dist/sdk/endpoints/private/sync/pull/draft.d.ts +0 -72
  95. package/dist/sdk/endpoints/private/sync/pull/draft.d.ts.map +0 -1
  96. package/dist/sdk/endpoints/private/sync/pull/draft.js +0 -36
  97. package/dist/sdk/endpoints/private/sync/pull/index.d.ts +0 -349
  98. package/dist/sdk/endpoints/private/sync/pull/index.d.ts.map +0 -1
  99. package/dist/sdk/endpoints/private/sync/pull/index.js +0 -6
  100. package/dist/sdk/endpoints/private/sync/pull/thread.d.ts +0 -100
  101. package/dist/sdk/endpoints/private/sync/pull/thread.d.ts.map +0 -1
  102. package/dist/sdk/endpoints/private/sync/pull/thread.js +0 -45
  103. package/dist/sdk/endpoints/private/sync/pull/user.d.ts +0 -57
  104. package/dist/sdk/endpoints/private/sync/pull/user.d.ts.map +0 -1
  105. package/dist/sdk/endpoints/private/sync/pull/user.js +0 -33
  106. package/dist/sdk/endpoints/private/sync/push/account.d.ts.map +0 -1
  107. package/dist/sdk/endpoints/private/sync/push/account.js +0 -73
  108. package/dist/sdk/endpoints/private/sync/push/draft.d.ts.map +0 -1
  109. package/dist/sdk/endpoints/private/sync/push/draft.js +0 -79
  110. package/dist/sdk/endpoints/private/sync/push/index.d.ts +0 -538
  111. package/dist/sdk/endpoints/private/sync/push/index.d.ts.map +0 -1
  112. package/dist/sdk/endpoints/private/sync/push/index.js +0 -5
  113. package/dist/sdk/endpoints/private/sync/push/thread.d.ts.map +0 -1
  114. package/dist/sdk/endpoints/private/sync/push/thread.js +0 -79
  115. package/dist/sdk/endpoints/private/sync/push/user.d.ts +0 -64
  116. package/dist/sdk/endpoints/private/sync/push/user.d.ts.map +0 -1
  117. package/dist/sdk/endpoints/private/sync/push/user.js +0 -43
  118. package/dist/types/MarcoClient.d.ts +0 -12
  119. package/dist/types/MarcoClient.d.ts.map +0 -1
  120. package/dist/types/MarcoClient.js +0 -1
  121. package/dist/types/WS.d.ts +0 -7
  122. package/dist/types/WS.d.ts.map +0 -1
  123. package/dist/types/WS.js +0 -1
  124. package/dist/ws.d.ts +0 -6
  125. package/dist/ws.d.ts.map +0 -1
  126. package/dist/ws.js +0 -5
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/sdk/endpoints/private/sync/index.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAiB,CAAA"}
@@ -1,3 +0,0 @@
1
- import { pull } from './pull';
2
- import { push } from './push';
3
- export const sync = { pull, push };
@@ -1,71 +0,0 @@
1
- import * as v from 'valibot';
2
- export declare const syncPullAccount: import("../../../../..").EndpointConfig<"/v1/pv/sync/pull/account", v.ObjectSchema<{
3
- readonly clientGroupID: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
4
- readonly cookie: v.NullableSchema<v.ObjectSchema<{
5
- readonly order: v.StringSchema<undefined>;
6
- readonly version: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
7
- }, undefined>, undefined>;
8
- }, undefined>, v.GenericSchema | undefined, v.UnionSchema<[v.ObjectSchema<{
9
- readonly data: v.ObjectSchema<{
10
- readonly code: v.LiteralSchema<"VALIDATION_FAILED", undefined>;
11
- readonly issues: v.ObjectSchema<{
12
- readonly nested: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
13
- readonly other: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
14
- readonly root: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
15
- }, undefined>;
16
- }, undefined>;
17
- readonly status: v.LiteralSchema<400, undefined>;
18
- }, undefined>, v.ObjectSchema<{
19
- readonly data: v.ObjectSchema<{
20
- readonly code: v.LiteralSchema<"AUTHENTICATION_FAILED", undefined>;
21
- }, undefined>;
22
- readonly status: v.LiteralSchema<401, undefined>;
23
- }, undefined>, v.ObjectSchema<{
24
- readonly data: v.ObjectSchema<{
25
- readonly cookie: v.ObjectSchema<{
26
- readonly order: v.StringSchema<undefined>;
27
- readonly version: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
28
- }, undefined>;
29
- readonly lastMutationIDChanges: v.RecordSchema<v.StringSchema<undefined>, v.NumberSchema<undefined>, undefined>;
30
- readonly patch: v.ArraySchema<v.UnionSchema<[v.ObjectSchema<{
31
- readonly op: v.LiteralSchema<"clear", undefined>;
32
- }, undefined>, v.ObjectSchema<{
33
- readonly key: v.StringSchema<undefined>;
34
- readonly op: v.LiteralSchema<"del", undefined>;
35
- }, undefined>, v.ObjectSchema<{
36
- readonly key: v.StringSchema<undefined>;
37
- readonly op: v.LiteralSchema<"put", undefined>;
38
- readonly value: v.ObjectSchema<{
39
- readonly aliases: v.ObjectSchema<{
40
- readonly nonPrimary: v.ArraySchema<v.ObjectSchema<{
41
- readonly emailAddress: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.EmailAction<string, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
42
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
43
- readonly name: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
44
- }, undefined>, undefined>;
45
- readonly primary: v.ObjectSchema<{
46
- readonly emailAddress: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.EmailAction<string, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
47
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
48
- readonly name: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
49
- }, undefined>;
50
- }, undefined>;
51
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
52
- readonly imapConnectionStatus: v.PicklistSchema<readonly ["AWAITING_CONNECTION", "CONNECTED", "CONNECTION_FAILED_AUTHENTICATION_ERROR", "CONNECTION_FAILED_CONNECTION_ERROR", "CONNECTION_FAILED_OAUTH_EXCHANGE_ERROR", "CONNECTION_FAILED_QUOTA_ERROR", "CONNECTION_FAILED_UNKNOWN_ERROR"], undefined>;
53
- readonly labels: v.ArraySchema<v.ObjectSchema<{
54
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
55
- readonly path: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
56
- readonly specialUse: v.NullableSchema<v.PicklistSchema<readonly ["ARCHIVE", "INBOX", "SENT", "SPAM", "TRASH"], undefined>, undefined>;
57
- }, undefined>, undefined>;
58
- readonly mailCounts: v.ObjectSchema<{
59
- readonly processed: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
60
- readonly total: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
61
- }, undefined>;
62
- readonly settings: v.ObjectSchema<{
63
- readonly color: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
64
- readonly name: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
65
- }, undefined>;
66
- }, undefined>;
67
- }, undefined>], undefined>, undefined>;
68
- }, undefined>;
69
- readonly status: v.LiteralSchema<200, undefined>;
70
- }, undefined>], undefined>>;
71
- //# sourceMappingURL=account.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"account.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/private/sync/pull/account.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAY5B,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAyB1B,CAAA"}
@@ -1,33 +0,0 @@
1
- import * as v from 'valibot';
2
- import { account } from '../../../../../clients/account';
3
- import { marcoSchemas } from '../../../../../schemas';
4
- import { createEndpoint } from '../../../../../sdk/endpoints/createEndpointConfig';
5
- import { errors } from '../../../../../sdk/validation/errors';
6
- const cookieSchema = v.object({
7
- order: v.string(),
8
- version: marcoSchemas.number.positiveInteger(),
9
- });
10
- export const syncPullAccount = createEndpoint({
11
- body: v.object({
12
- clientGroupID: marcoSchemas.string.required(),
13
- cookie: v.nullable(cookieSchema),
14
- }),
15
- method: 'POST',
16
- path: account.pullUrl,
17
- response: v.union([
18
- errors.validationFailedErrorSchema,
19
- errors.authFailedErrorSchema,
20
- v.object({
21
- data: v.object({
22
- cookie: cookieSchema,
23
- lastMutationIDChanges: v.record(v.string(), v.number()),
24
- patch: v.array(v.union([
25
- v.object({ op: v.literal('clear') }),
26
- v.object({ key: v.string(), op: v.literal('del') }),
27
- v.object({ key: v.string(), op: v.literal('put'), value: account.model }),
28
- ])),
29
- }),
30
- status: v.literal(200),
31
- }),
32
- ]),
33
- });
@@ -1,56 +0,0 @@
1
- import * as v from 'valibot';
2
- export declare const syncPullContact: import("../../../../..").EndpointConfig<"/v1/pv/sync/pull/contact", v.ObjectSchema<{
3
- readonly clientGroupID: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
4
- readonly cookie: v.NullableSchema<v.ObjectSchema<{
5
- readonly hasMore: v.BooleanSchema<undefined>;
6
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
7
- readonly order: v.StringSchema<undefined>;
8
- readonly versionMax: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
9
- readonly versionMin: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
10
- }, undefined>, undefined>;
11
- }, undefined>, v.ObjectSchema<{
12
- readonly pageSize: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TransformAction<any, number>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>]>, undefined>;
13
- }, undefined>, v.UnionSchema<[v.ObjectSchema<{
14
- readonly data: v.ObjectSchema<{
15
- readonly code: v.LiteralSchema<"VALIDATION_FAILED", undefined>;
16
- readonly issues: v.ObjectSchema<{
17
- readonly nested: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
18
- readonly other: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
19
- readonly root: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
20
- }, undefined>;
21
- }, undefined>;
22
- readonly status: v.LiteralSchema<400, undefined>;
23
- }, undefined>, v.ObjectSchema<{
24
- readonly data: v.ObjectSchema<{
25
- readonly code: v.LiteralSchema<"AUTHENTICATION_FAILED", undefined>;
26
- }, undefined>;
27
- readonly status: v.LiteralSchema<401, undefined>;
28
- }, undefined>, v.ObjectSchema<{
29
- readonly data: v.ObjectSchema<{
30
- readonly cookie: v.ObjectSchema<{
31
- readonly hasMore: v.BooleanSchema<undefined>;
32
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
33
- readonly order: v.StringSchema<undefined>;
34
- readonly versionMax: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
35
- readonly versionMin: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
36
- }, undefined>;
37
- readonly hasMore: v.BooleanSchema<undefined>;
38
- readonly lastMutationIDChanges: v.RecordSchema<v.StringSchema<undefined>, v.NumberSchema<undefined>, undefined>;
39
- readonly patch: v.ArraySchema<v.UnionSchema<[v.ObjectSchema<{
40
- readonly op: v.LiteralSchema<"clear", undefined>;
41
- }, undefined>, v.ObjectSchema<{
42
- readonly key: v.StringSchema<undefined>;
43
- readonly op: v.LiteralSchema<"del", undefined>;
44
- }, undefined>, v.ObjectSchema<{
45
- readonly key: v.StringSchema<undefined>;
46
- readonly op: v.LiteralSchema<"put", undefined>;
47
- readonly value: v.ObjectSchema<{
48
- readonly emailAddress: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.EmailAction<string, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
49
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
50
- readonly name: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
51
- }, undefined>;
52
- }, undefined>], undefined>, undefined>;
53
- }, undefined>;
54
- readonly status: v.LiteralSchema<200, undefined>;
55
- }, undefined>], undefined>>;
56
- //# sourceMappingURL=contact.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"contact.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/private/sync/pull/contact.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAe5B,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BA6B1B,CAAA"}
@@ -1,40 +0,0 @@
1
- import * as v from 'valibot';
2
- import { contact } from '../../../../../clients/contact';
3
- import { marcoSchemas } from '../../../../../schemas';
4
- import { createEndpoint } from '../../../../../sdk/endpoints/createEndpointConfig';
5
- import { errors } from '../../../../../sdk/validation/errors';
6
- const cookieSchema = v.object({
7
- hasMore: v.boolean(),
8
- id: marcoSchemas.number.positiveInteger(),
9
- order: v.string(),
10
- versionMax: marcoSchemas.number.positiveInteger(),
11
- versionMin: marcoSchemas.number.positiveInteger(),
12
- });
13
- export const syncPullContact = createEndpoint({
14
- body: v.object({
15
- clientGroupID: marcoSchemas.string.required(),
16
- cookie: v.nullable(cookieSchema),
17
- }),
18
- method: 'POST',
19
- path: contact.pullUrl,
20
- query: v.object({
21
- pageSize: v.optional(v.pipe(v.string(), v.transform(Number), v.integer(), v.minValue(1))),
22
- }),
23
- response: v.union([
24
- errors.validationFailedErrorSchema,
25
- errors.authFailedErrorSchema,
26
- v.object({
27
- data: v.object({
28
- cookie: cookieSchema,
29
- hasMore: v.boolean(),
30
- lastMutationIDChanges: v.record(v.string(), v.number()),
31
- patch: v.array(v.union([
32
- v.object({ op: v.literal('clear') }),
33
- v.object({ key: v.string(), op: v.literal('del') }),
34
- v.object({ key: v.string(), op: v.literal('put'), value: contact.model }),
35
- ])),
36
- }),
37
- status: v.literal(200),
38
- }),
39
- ]),
40
- });
@@ -1,72 +0,0 @@
1
- import * as v from 'valibot';
2
- export declare const syncPullDraft: import("../../../../..").EndpointConfig<"/v1/pv/sync/pull/draft", v.ObjectSchema<{
3
- readonly clientGroupID: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
4
- readonly cookie: v.NullableSchema<v.ObjectSchema<{
5
- readonly order: v.StringSchema<undefined>;
6
- readonly version: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
7
- }, undefined>, undefined>;
8
- }, undefined>, v.ObjectSchema<{
9
- readonly pageSize: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>]>, undefined>;
10
- }, undefined>, v.UnionSchema<[v.ObjectSchema<{
11
- readonly data: v.ObjectSchema<{
12
- readonly code: v.LiteralSchema<"VALIDATION_FAILED", undefined>;
13
- readonly issues: v.ObjectSchema<{
14
- readonly nested: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
15
- readonly other: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
16
- readonly root: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
17
- }, undefined>;
18
- }, undefined>;
19
- readonly status: v.LiteralSchema<400, undefined>;
20
- }, undefined>, v.ObjectSchema<{
21
- readonly data: v.ObjectSchema<{
22
- readonly code: v.LiteralSchema<"AUTHENTICATION_FAILED", undefined>;
23
- }, undefined>;
24
- readonly status: v.LiteralSchema<401, undefined>;
25
- }, undefined>, v.ObjectSchema<{
26
- readonly data: v.ObjectSchema<{
27
- readonly cookie: v.ObjectSchema<{
28
- readonly order: v.StringSchema<undefined>;
29
- readonly version: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
30
- }, undefined>;
31
- readonly lastMutationIDChanges: v.RecordSchema<v.StringSchema<undefined>, v.NumberSchema<undefined>, undefined>;
32
- readonly patch: v.ArraySchema<v.UnionSchema<[v.ObjectSchema<{
33
- readonly op: v.LiteralSchema<"clear", undefined>;
34
- }, undefined>, v.ObjectSchema<{
35
- readonly key: v.StringSchema<undefined>;
36
- readonly op: v.LiteralSchema<"del", undefined>;
37
- }, undefined>, v.ObjectSchema<{
38
- readonly key: v.StringSchema<undefined>;
39
- readonly op: v.LiteralSchema<"put", undefined>;
40
- readonly value: v.ObjectSchema<{
41
- readonly attachments: v.ArraySchema<v.ObjectSchema<{
42
- readonly failed: v.BooleanSchema<undefined>;
43
- readonly fileName: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
44
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
45
- readonly mimeType: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
46
- readonly totalChunks: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
47
- readonly totalSize: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
48
- readonly uploadedChunks: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
49
- }, undefined>, undefined>;
50
- readonly body: v.ObjectSchema<{
51
- readonly bcc: v.ArraySchema<v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.EmailAction<string, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>, undefined>;
52
- readonly cc: v.ArraySchema<v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.EmailAction<string, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>, undefined>;
53
- readonly content: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 384000, undefined>]>;
54
- readonly subject: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
55
- readonly to: v.ArraySchema<v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.EmailAction<string, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>, undefined>;
56
- }, undefined>;
57
- readonly emailAccountId: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
58
- readonly error: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
59
- readonly from: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.EmailAction<string, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
60
- readonly fromName: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
61
- readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
62
- readonly referencedMessageId: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
63
- readonly scheduledFor: v.NullableSchema<v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>, undefined>;
64
- readonly status: v.PicklistSchema<readonly ["DRAFT", "SEND_REQUESTED", "SEND_CONFIRMED", "SEND_FAILED"], undefined>;
65
- readonly type: v.PicklistSchema<readonly ["NEW", "REPLY", "FORWARD"], undefined>;
66
- readonly updatedAt: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
67
- }, undefined>;
68
- }, undefined>], undefined>, undefined>;
69
- }, undefined>;
70
- readonly status: v.LiteralSchema<200, undefined>;
71
- }, undefined>], undefined>>;
72
- //# sourceMappingURL=draft.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"draft.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/private/sync/pull/draft.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAY5B,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BA4BxB,CAAA"}
@@ -1,36 +0,0 @@
1
- import * as v from 'valibot';
2
- import { draft } from '../../../../../clients/draft';
3
- import { marcoSchemas } from '../../../../../schemas';
4
- import { createEndpoint } from '../../../../../sdk/endpoints/createEndpointConfig';
5
- import { errors } from '../../../../../sdk/validation/errors';
6
- const cookieSchema = v.object({
7
- order: v.string(),
8
- version: marcoSchemas.number.positiveInteger(),
9
- });
10
- export const syncPullDraft = createEndpoint({
11
- body: v.object({
12
- clientGroupID: marcoSchemas.string.required(),
13
- cookie: v.nullable(cookieSchema),
14
- }),
15
- method: 'POST',
16
- path: draft.pullUrl,
17
- query: v.object({
18
- pageSize: v.optional(v.pipe(v.number(), v.integer(), v.minValue(1))),
19
- }),
20
- response: v.union([
21
- errors.validationFailedErrorSchema,
22
- errors.authFailedErrorSchema,
23
- v.object({
24
- data: v.object({
25
- cookie: cookieSchema,
26
- lastMutationIDChanges: v.record(v.string(), v.number()),
27
- patch: v.array(v.union([
28
- v.object({ op: v.literal('clear') }),
29
- v.object({ key: v.string(), op: v.literal('del') }),
30
- v.object({ key: v.string(), op: v.literal('put'), value: draft.model }),
31
- ])),
32
- }),
33
- status: v.literal(200),
34
- }),
35
- ]),
36
- });