@marcoappio/marco-config 2.0.351 → 2.0.352

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 (73) hide show
  1. package/dist/clients/draft.d.ts +4 -4
  2. package/dist/clients/draft.js +2 -2
  3. package/dist/clients/index.d.ts +4 -4
  4. package/dist/index.d.ts +1 -1
  5. package/dist/index.d.ts.map +1 -1
  6. package/dist/index.js +1 -1
  7. package/dist/schemas/index.d.ts +1 -2
  8. package/dist/schemas/index.d.ts.map +1 -1
  9. package/dist/schemas/number.d.ts +1 -0
  10. package/dist/schemas/number.d.ts.map +1 -1
  11. package/dist/schemas/number.js +1 -0
  12. package/dist/schemas/string.d.ts +0 -2
  13. package/dist/schemas/string.d.ts.map +1 -1
  14. package/dist/schemas/string.js +0 -3
  15. package/dist/sdk/endpoints/index.d.ts +20 -20
  16. package/dist/sdk/endpoints/private/emailMessage/getEmailMessageHTML.d.ts +1 -1
  17. package/dist/sdk/endpoints/private/emailMessage/getEmailMessageHTML.d.ts.map +1 -1
  18. package/dist/sdk/endpoints/private/emailMessage/getEmailMessageHTML.js +2 -1
  19. package/dist/sdk/endpoints/private/emailMessage/index.d.ts +1 -1
  20. package/dist/sdk/endpoints/private/index.d.ts +12 -12
  21. package/dist/sdk/endpoints/private/sync/index.d.ts +11 -11
  22. package/dist/sdk/endpoints/private/sync/pull/account.d.ts +1 -1
  23. package/dist/sdk/endpoints/private/sync/pull/account.d.ts.map +1 -1
  24. package/dist/sdk/endpoints/private/sync/pull/account.js +3 -2
  25. package/dist/sdk/endpoints/private/sync/pull/contact.d.ts +1 -1
  26. package/dist/sdk/endpoints/private/sync/pull/contact.d.ts.map +1 -1
  27. package/dist/sdk/endpoints/private/sync/pull/contact.js +3 -2
  28. package/dist/sdk/endpoints/private/sync/pull/draft.d.ts +3 -3
  29. package/dist/sdk/endpoints/private/sync/pull/draft.d.ts.map +1 -1
  30. package/dist/sdk/endpoints/private/sync/pull/draft.js +3 -2
  31. package/dist/sdk/endpoints/private/sync/pull/index.d.ts +9 -9
  32. package/dist/sdk/endpoints/private/sync/pull/thread.d.ts +3 -3
  33. package/dist/sdk/endpoints/private/sync/pull/thread.d.ts.map +1 -1
  34. package/dist/sdk/endpoints/private/sync/pull/thread.js +4 -3
  35. package/dist/sdk/endpoints/private/sync/pull/user.d.ts +1 -1
  36. package/dist/sdk/endpoints/private/sync/pull/user.d.ts.map +1 -1
  37. package/dist/sdk/endpoints/private/sync/pull/user.js +3 -2
  38. package/dist/sdk/endpoints/private/sync/push/draft.d.ts +2 -2
  39. package/dist/sdk/endpoints/private/sync/push/index.d.ts +2 -2
  40. package/dist/sdk/endpoints/private/sync/push/thread.d.ts.map +1 -1
  41. package/dist/sdk/endpoints/private/sync/push/thread.js +2 -1
  42. package/dist/sdk/endpoints/public/auth/index.d.ts +7 -7
  43. package/dist/sdk/endpoints/public/auth/refreshAuth.d.ts +4 -4
  44. package/dist/sdk/endpoints/public/auth/refreshAuth.js +4 -4
  45. package/dist/sdk/endpoints/public/auth/verifyAuthCode.d.ts +3 -3
  46. package/dist/sdk/endpoints/public/auth/verifyAuthCode.js +3 -3
  47. package/dist/sdk/endpoints/public/config/index.d.ts +1 -1
  48. package/dist/sdk/endpoints/public/config/index.d.ts.map +1 -1
  49. package/dist/sdk/endpoints/public/config/index.js +2 -1
  50. package/dist/sdk/endpoints/public/index.d.ts +8 -8
  51. package/dist/sdk/index.d.ts +20 -20
  52. package/dist/utils/accounts/index.d.ts.map +1 -1
  53. package/dist/utils/index.d.ts +0 -1
  54. package/dist/utils/index.d.ts.map +1 -1
  55. package/dist/utils/index.js +0 -1
  56. package/dist/ws.d.ts.map +1 -1
  57. package/dist/ws.js +1 -6
  58. package/package.json +3 -4
  59. package/dist/schemas/string.test.d.ts +0 -2
  60. package/dist/schemas/string.test.d.ts.map +0 -1
  61. package/dist/schemas/string.test.js +0 -20
  62. package/dist/utils/accounts/labelIdGenerate.d.ts +0 -5
  63. package/dist/utils/accounts/labelIdGenerate.d.ts.map +0 -1
  64. package/dist/utils/accounts/labelIdGenerate.js +0 -6
  65. package/dist/utils/shortUUID/index.d.ts +0 -2
  66. package/dist/utils/shortUUID/index.d.ts.map +0 -1
  67. package/dist/utils/shortUUID/index.js +0 -1
  68. package/dist/utils/shortUUID/shortUUID.d.ts +0 -7
  69. package/dist/utils/shortUUID/shortUUID.d.ts.map +0 -1
  70. package/dist/utils/shortUUID/shortUUID.js +0 -8
  71. package/dist/utils/shortUUID/shortUUID.test.d.ts +0 -2
  72. package/dist/utils/shortUUID/shortUUID.test.d.ts.map +0 -1
  73. package/dist/utils/shortUUID/shortUUID.test.js +0 -19
@@ -2,7 +2,7 @@ import * as v from 'valibot';
2
2
  export declare const config: import("../../../..").EndpointConfig<"/v1/pb/config", v.GenericSchema<unknown, unknown, v.BaseIssue<unknown>> | undefined, v.GenericSchema<unknown, unknown, v.BaseIssue<unknown>> | undefined, v.ObjectSchema<{
3
3
  readonly data: v.ObjectSchema<{
4
4
  readonly app: v.ObjectSchema<{
5
- readonly minimumVersion: v.StringSchema<undefined>;
5
+ readonly minimumVersion: v.NonOptionalSchema<v.SchemaWithPipe<[v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
6
6
  }, undefined>;
7
7
  }, undefined>;
8
8
  readonly status: v.LiteralSchema<200, undefined>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/sdk/endpoints/public/config/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAI5B,eAAO,MAAM,MAAM;;;;;;;cAWjB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/sdk/endpoints/public/config/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAK5B,eAAO,MAAM,MAAM;;;;;;;cAWjB,CAAA"}
@@ -1,4 +1,5 @@
1
1
  import * as v from 'valibot';
2
+ import { marcoSchemas } from '../../../../schemas';
2
3
  import { createEndpoint } from '../../../../sdk/endpoints/createEndpointConfig';
3
4
  export const config = createEndpoint({
4
5
  method: 'GET',
@@ -6,7 +7,7 @@ export const config = createEndpoint({
6
7
  response: v.object({
7
8
  data: v.object({
8
9
  app: v.object({
9
- minimumVersion: v.string(),
10
+ minimumVersion: marcoSchemas.string.required(),
10
11
  }),
11
12
  }),
12
13
  status: v.literal(200),
@@ -1,7 +1,7 @@
1
1
  export declare const publicGroup: {
2
2
  auth: {
3
3
  refreshAuth: import("../../..").EndpointConfig<"/v1/pb/auth/refresh", import("valibot").ObjectSchema<{
4
- readonly refreshToken: import("valibot").StringSchema<undefined>;
4
+ readonly refreshToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
5
5
  }, undefined>, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").UnionSchema<[import("valibot").ObjectSchema<{
6
6
  readonly data: import("valibot").ObjectSchema<{
7
7
  readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
@@ -24,14 +24,14 @@ export declare const publicGroup: {
24
24
  readonly status: import("valibot").LiteralSchema<502, undefined>;
25
25
  }, undefined>, import("valibot").ObjectSchema<{
26
26
  readonly data: import("valibot").ObjectSchema<{
27
- readonly accessToken: import("valibot").StringSchema<undefined>;
28
- readonly refreshToken: import("valibot").StringSchema<undefined>;
27
+ readonly accessToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
28
+ readonly refreshToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
29
29
  readonly user: import("valibot").ObjectSchema<{
30
30
  readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
31
31
  readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>;
32
32
  readonly emailVerified: import("valibot").BooleanSchema<undefined>;
33
33
  readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
34
- readonly id: import("valibot").StringSchema<undefined>;
34
+ readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
35
35
  readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
36
36
  readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
37
37
  readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
@@ -119,14 +119,14 @@ export declare const publicGroup: {
119
119
  readonly status: import("valibot").LiteralSchema<409, undefined>;
120
120
  }, undefined>, import("valibot").ObjectSchema<{
121
121
  readonly data: import("valibot").ObjectSchema<{
122
- readonly accessToken: import("valibot").StringSchema<undefined>;
123
- readonly refreshToken: import("valibot").StringSchema<undefined>;
122
+ readonly accessToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
123
+ readonly refreshToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
124
124
  readonly user: import("valibot").ObjectSchema<{
125
125
  readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
126
126
  readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>;
127
127
  readonly emailVerified: import("valibot").BooleanSchema<undefined>;
128
128
  readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
129
- readonly id: import("valibot").StringSchema<undefined>;
129
+ readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
130
130
  readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
131
131
  readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
132
132
  readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
@@ -138,7 +138,7 @@ export declare const publicGroup: {
138
138
  config: import("../../..").EndpointConfig<"/v1/pb/config", import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").ObjectSchema<{
139
139
  readonly data: import("valibot").ObjectSchema<{
140
140
  readonly app: import("valibot").ObjectSchema<{
141
- readonly minimumVersion: import("valibot").StringSchema<undefined>;
141
+ readonly minimumVersion: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
142
142
  }, undefined>;
143
143
  }, undefined>;
144
144
  readonly status: import("valibot").LiteralSchema<200, undefined>;
@@ -28,7 +28,7 @@ export declare const marcoSDK: {
28
28
  readonly status: import("valibot").LiteralSchema<404, undefined>;
29
29
  }, undefined>, import("valibot").ObjectSchema<{
30
30
  readonly data: import("valibot").ObjectSchema<{
31
- readonly html: import("valibot").StringSchema<undefined>;
31
+ readonly html: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
32
32
  }, undefined>;
33
33
  readonly status: import("valibot").LiteralSchema<200, undefined>;
34
34
  }, undefined>], undefined>>;
@@ -36,7 +36,7 @@ export declare const marcoSDK: {
36
36
  sync: {
37
37
  pull: {
38
38
  account: import("..").EndpointConfig<"/v1/pv/sync/pull/account", import("valibot").ObjectSchema<{
39
- readonly clientGroupID: import("valibot").StringSchema<undefined>;
39
+ readonly clientGroupID: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
40
40
  readonly cookie: import("valibot").NullableSchema<import("valibot").NumberSchema<undefined>, undefined>;
41
41
  }, undefined>, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").UnionSchema<[import("valibot").ObjectSchema<{
42
42
  readonly data: import("valibot").ObjectSchema<{
@@ -99,7 +99,7 @@ export declare const marcoSDK: {
99
99
  readonly status: import("valibot").LiteralSchema<200, undefined>;
100
100
  }, undefined>], undefined>>;
101
101
  contact: import("..").EndpointConfig<"/v1/pv/sync/pull/contact", import("valibot").ObjectSchema<{
102
- readonly clientGroupID: import("valibot").StringSchema<undefined>;
102
+ readonly clientGroupID: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
103
103
  readonly cookie: import("valibot").NullableSchema<import("valibot").NumberSchema<undefined>, undefined>;
104
104
  }, undefined>, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").UnionSchema<[import("valibot").ObjectSchema<{
105
105
  readonly data: import("valibot").ObjectSchema<{
@@ -138,7 +138,7 @@ export declare const marcoSDK: {
138
138
  readonly status: import("valibot").LiteralSchema<200, undefined>;
139
139
  }, undefined>], undefined>>;
140
140
  draft: import("..").EndpointConfig<"/v1/pv/sync/pull/draft", import("valibot").ObjectSchema<{
141
- readonly clientGroupID: import("valibot").StringSchema<undefined>;
141
+ readonly clientGroupID: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
142
142
  readonly cookie: import("valibot").NullableSchema<import("valibot").NumberSchema<undefined>, undefined>;
143
143
  }, undefined>, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").UnionSchema<[import("valibot").ObjectSchema<{
144
144
  readonly data: import("valibot").ObjectSchema<{
@@ -185,11 +185,11 @@ export declare const marcoSDK: {
185
185
  readonly to: import("valibot").ArraySchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>, undefined>;
186
186
  }, undefined>;
187
187
  readonly emailAccountId: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
188
- readonly error: import("valibot").NullableSchema<import("valibot").StringSchema<undefined>, undefined>;
188
+ readonly error: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
189
189
  readonly from: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>;
190
190
  readonly fromName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
191
191
  readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
192
- readonly referencedMessageId: import("valibot").NullableSchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>, undefined>;
192
+ readonly referencedMessageId: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
193
193
  readonly scheduledFor: import("valibot").NullableSchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").NumberSchema<undefined>, import("valibot").IntegerAction<number, undefined>, import("valibot").MinValueAction<number, 0, undefined>]>, undefined>, undefined>;
194
194
  readonly status: import("valibot").UnionSchema<[import("valibot").LiteralSchema<"DRAFT", undefined>, import("valibot").LiteralSchema<"SEND_REQUESTED", undefined>, import("valibot").LiteralSchema<"SEND_CONFIRMATION_PENDING", undefined>, import("valibot").LiteralSchema<"SEND_CONFIRMED", undefined>], undefined>;
195
195
  readonly type: import("valibot").UnionSchema<[import("valibot").LiteralSchema<"NEW", undefined>, import("valibot").LiteralSchema<"REPLY", undefined>, import("valibot").LiteralSchema<"FORWARD", undefined>], undefined>;
@@ -200,10 +200,10 @@ export declare const marcoSDK: {
200
200
  readonly status: import("valibot").LiteralSchema<200, undefined>;
201
201
  }, undefined>], undefined>>;
202
202
  thread: import("..").EndpointConfig<"/v1/pv/sync/pull/thread", import("valibot").ObjectSchema<{
203
- readonly clientGroupID: import("valibot").StringSchema<undefined>;
203
+ readonly clientGroupID: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
204
204
  readonly cookie: import("valibot").NullableSchema<import("valibot").ObjectSchema<{
205
205
  readonly hasMore: import("valibot").BooleanSchema<undefined>;
206
- readonly id: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>, undefined>;
206
+ readonly id: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
207
207
  readonly latestSentAt: import("valibot").NullableSchema<import("valibot").NumberSchema<undefined>, undefined>;
208
208
  readonly order: import("valibot").StringSchema<undefined>;
209
209
  readonly versionMax: import("valibot").NumberSchema<undefined>;
@@ -228,7 +228,7 @@ export declare const marcoSDK: {
228
228
  readonly data: import("valibot").ObjectSchema<{
229
229
  readonly cookie: import("valibot").ObjectSchema<{
230
230
  readonly hasMore: import("valibot").BooleanSchema<undefined>;
231
- readonly id: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>, undefined>;
231
+ readonly id: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
232
232
  readonly latestSentAt: import("valibot").NullableSchema<import("valibot").NumberSchema<undefined>, undefined>;
233
233
  readonly order: import("valibot").StringSchema<undefined>;
234
234
  readonly versionMax: import("valibot").NumberSchema<undefined>;
@@ -290,7 +290,7 @@ export declare const marcoSDK: {
290
290
  readonly status: import("valibot").LiteralSchema<200, undefined>;
291
291
  }, undefined>], undefined>>;
292
292
  user: import("..").EndpointConfig<"/v1/pv/sync/pull/user", import("valibot").ObjectSchema<{
293
- readonly clientGroupID: import("valibot").StringSchema<undefined>;
293
+ readonly clientGroupID: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
294
294
  readonly cookie: import("valibot").NullableSchema<import("valibot").NumberSchema<undefined>, undefined>;
295
295
  }, undefined>, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").UnionSchema<[import("valibot").ObjectSchema<{
296
296
  readonly data: import("valibot").ObjectSchema<{
@@ -531,11 +531,11 @@ export declare const marcoSDK: {
531
531
  readonly to: import("valibot").ArraySchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>, undefined>;
532
532
  }, undefined>;
533
533
  readonly emailAccountId: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
534
- readonly error: import("valibot").NullableSchema<import("valibot").StringSchema<undefined>, undefined>;
534
+ readonly error: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
535
535
  readonly from: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>;
536
536
  readonly fromName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
537
537
  readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
538
- readonly referencedMessageId: import("valibot").NullableSchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>, undefined>;
538
+ readonly referencedMessageId: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
539
539
  readonly scheduledFor: import("valibot").NullableSchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").NumberSchema<undefined>, import("valibot").IntegerAction<number, undefined>, import("valibot").MinValueAction<number, 0, undefined>]>, undefined>, undefined>;
540
540
  readonly status: import("valibot").UnionSchema<[import("valibot").LiteralSchema<"DRAFT", undefined>, import("valibot").LiteralSchema<"SEND_REQUESTED", undefined>, import("valibot").LiteralSchema<"SEND_CONFIRMATION_PENDING", undefined>, import("valibot").LiteralSchema<"SEND_CONFIRMED", undefined>], undefined>;
541
541
  readonly type: import("valibot").UnionSchema<[import("valibot").LiteralSchema<"NEW", undefined>, import("valibot").LiteralSchema<"REPLY", undefined>, import("valibot").LiteralSchema<"FORWARD", undefined>], undefined>;
@@ -845,7 +845,7 @@ export declare const marcoSDK: {
845
845
  public: {
846
846
  auth: {
847
847
  refreshAuth: import("..").EndpointConfig<"/v1/pb/auth/refresh", import("valibot").ObjectSchema<{
848
- readonly refreshToken: import("valibot").StringSchema<undefined>;
848
+ readonly refreshToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
849
849
  }, undefined>, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").UnionSchema<[import("valibot").ObjectSchema<{
850
850
  readonly data: import("valibot").ObjectSchema<{
851
851
  readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
@@ -868,14 +868,14 @@ export declare const marcoSDK: {
868
868
  readonly status: import("valibot").LiteralSchema<502, undefined>;
869
869
  }, undefined>, import("valibot").ObjectSchema<{
870
870
  readonly data: import("valibot").ObjectSchema<{
871
- readonly accessToken: import("valibot").StringSchema<undefined>;
872
- readonly refreshToken: import("valibot").StringSchema<undefined>;
871
+ readonly accessToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
872
+ readonly refreshToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
873
873
  readonly user: import("valibot").ObjectSchema<{
874
874
  readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
875
875
  readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>;
876
876
  readonly emailVerified: import("valibot").BooleanSchema<undefined>;
877
877
  readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
878
- readonly id: import("valibot").StringSchema<undefined>;
878
+ readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
879
879
  readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
880
880
  readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
881
881
  readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
@@ -963,14 +963,14 @@ export declare const marcoSDK: {
963
963
  readonly status: import("valibot").LiteralSchema<409, undefined>;
964
964
  }, undefined>, import("valibot").ObjectSchema<{
965
965
  readonly data: import("valibot").ObjectSchema<{
966
- readonly accessToken: import("valibot").StringSchema<undefined>;
967
- readonly refreshToken: import("valibot").StringSchema<undefined>;
966
+ readonly accessToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
967
+ readonly refreshToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
968
968
  readonly user: import("valibot").ObjectSchema<{
969
969
  readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
970
970
  readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").EmailAction<string, undefined>, import("valibot").MaxLengthAction<string, 255, undefined>]>, undefined>;
971
971
  readonly emailVerified: import("valibot").BooleanSchema<undefined>;
972
972
  readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
973
- readonly id: import("valibot").StringSchema<undefined>;
973
+ readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
974
974
  readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
975
975
  readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
976
976
  readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
@@ -982,7 +982,7 @@ export declare const marcoSDK: {
982
982
  config: import("..").EndpointConfig<"/v1/pb/config", import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").GenericSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | undefined, import("valibot").ObjectSchema<{
983
983
  readonly data: import("valibot").ObjectSchema<{
984
984
  readonly app: import("valibot").ObjectSchema<{
985
- readonly minimumVersion: import("valibot").StringSchema<undefined>;
985
+ readonly minimumVersion: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<[import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
986
986
  }, undefined>;
987
987
  }, undefined>;
988
988
  readonly status: import("valibot").LiteralSchema<200, undefined>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/accounts/index.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY;;CAGxB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/accounts/index.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY;;CAExB,CAAA"}
@@ -1,4 +1,3 @@
1
1
  export { accountUtils } from './accounts';
2
- export { shortUUID } from './shortUUID';
3
2
  export { stringPatch } from './stringPatch';
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAA;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAA;AACzC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAA"}
@@ -1,3 +1,2 @@
1
1
  export { accountUtils } from './accounts';
2
- export { shortUUID } from './shortUUID';
3
2
  export { stringPatch } from './stringPatch';
package/dist/ws.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"ws.d.ts","sourceRoot":"","sources":["../src/ws.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,OAAO;;uBAED,MAAM;;CAMxB,CAAA"}
1
+ {"version":3,"file":"ws.d.ts","sourceRoot":"","sources":["../src/ws.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO;;uBAED,MAAM;;CAExB,CAAA"}
package/dist/ws.js CHANGED
@@ -1,10 +1,5 @@
1
- import * as v from 'valibot';
2
- import { marcoSchemas } from './schemas';
3
1
  export const marcoWS = {
4
2
  getChannelName: {
5
- user: (userId) => {
6
- v.parse(marcoSchemas.string.required(), userId);
7
- return userId;
8
- },
3
+ user: (userId) => userId,
9
4
  },
10
5
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@marcoappio/marco-config",
3
3
  "packageManager": "bun@1.2.0",
4
- "version": "2.0.351",
4
+ "version": "2.0.352",
5
5
  "author": "team@marcoapp.io",
6
6
  "main": "dist/index.js",
7
7
  "repository": "git@github.com:marcoappio/marco-config.git",
@@ -18,10 +18,10 @@
18
18
  "build": "tsc && tsc-alias",
19
19
  "lint": "eslint --ext .ts,.tsx,.js src",
20
20
  "release": "bun run build && auto shipit",
21
+ "test": "bun test",
21
22
  "typecheck": "tsc -noEmit --incremental"
22
23
  },
23
24
  "dependencies": {
24
- "@types/bun": "1.2.0",
25
25
  "@typescript-eslint/eslint-plugin": "5.62.0",
26
26
  "@typescript-eslint/parser": "6.21.0",
27
27
  "diff": "8.0.0-beta",
@@ -33,12 +33,11 @@
33
33
  "eslint-plugin-sort-destructure-keys": "1.4.0",
34
34
  "eslint-plugin-sort-keys-fix": "1.1.2",
35
35
  "eslint-plugin-typescript-sort-keys": "2.3.0",
36
- "short-uuid": "5.2.0",
37
- "uuid": "11.1.0",
38
36
  "valibot": "1.0.0-beta.9"
39
37
  },
40
38
  "devDependencies": {
41
39
  "@auto-it/npm": "11.2.0",
40
+ "@types/bun": "1.2.0",
42
41
  "auto": "11.2.0",
43
42
  "tsc-alias": "1.8.16",
44
43
  "typescript": "5.7.3"
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=string.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"string.test.d.ts","sourceRoot":"","sources":["../../src/schemas/string.test.ts"],"names":[],"mappings":""}
@@ -1,20 +0,0 @@
1
- import { describe, expect, it } from 'bun:test';
2
- import * as v from 'valibot';
3
- import { string } from '../schemas/string';
4
- import { shortUUID } from '../utils';
5
- describe('string', () => {
6
- const uuid = shortUUID.createUUID();
7
- const uuidShort = shortUUID.fromUUID(uuid);
8
- describe('shortUUID', () => {
9
- it('should correctly validate a short UUID', () => {
10
- expect(v.safeParse(string.shortUUID(), uuidShort).success).toBe(true);
11
- expect(v.safeParse(string.shortUUID(), uuid).success).toBe(false);
12
- });
13
- });
14
- describe('uuid', () => {
15
- it('should correctly validate a UUID', () => {
16
- expect(v.safeParse(string.uuid(), uuid).success).toBe(true);
17
- expect(v.safeParse(string.uuid(), uuidShort).success).toBe(false);
18
- });
19
- });
20
- });
@@ -1,5 +0,0 @@
1
- export declare const labelIdGenerate: (params: {
2
- accountId: string;
3
- path: string;
4
- }) => string;
5
- //# sourceMappingURL=labelIdGenerate.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"labelIdGenerate.d.ts","sourceRoot":"","sources":["../../../src/utils/accounts/labelIdGenerate.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,eAAe,WAAY;IACpC,SAAS,EAAE,MAAM,CAAA;IACjB,IAAI,EAAE,MAAM,CAAA;CACf,WAOA,CAAA"}
@@ -1,6 +0,0 @@
1
- import { v5 as uuidv5 } from 'uuid';
2
- import { shortUUID } from '../../utils/shortUUID/shortUUID';
3
- export const labelIdGenerate = (params) => {
4
- const val = uuidv5(JSON.stringify([params.accountId, params.path]), uuidv5.URL);
5
- return shortUUID.fromUUID(val);
6
- };
@@ -1,2 +0,0 @@
1
- export { shortUUID } from './shortUUID';
2
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/shortUUID/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA"}
@@ -1 +0,0 @@
1
- export { shortUUID } from './shortUUID';
@@ -1,7 +0,0 @@
1
- export declare const shortUUID: {
2
- createUUID: () => string;
3
- fromUUID: (uuid: string) => string;
4
- toUUID: (shortUUID: string) => string;
5
- validate: (uuid: string) => boolean;
6
- };
7
- //# sourceMappingURL=shortUUID.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"shortUUID.d.ts","sourceRoot":"","sources":["../../../src/utils/shortUUID/shortUUID.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,SAAS;sBACmB,MAAM;qBAC5B,MAAM,KAAkC,MAAM;wBAC3C,MAAM,KAAqC,MAAM;qBACpD,MAAM,KAAkC,OAAO;CACjE,CAAA"}
@@ -1,8 +0,0 @@
1
- import short from 'short-uuid';
2
- const translator = short();
3
- export const shortUUID = {
4
- createUUID: () => translator.uuid(),
5
- fromUUID: (uuid) => translator.fromUUID(uuid),
6
- toUUID: (shortUUID) => translator.toUUID(shortUUID),
7
- validate: (uuid) => translator.validate(uuid),
8
- };
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=shortUUID.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"shortUUID.test.d.ts","sourceRoot":"","sources":["../../../src/utils/shortUUID/shortUUID.test.ts"],"names":[],"mappings":""}
@@ -1,19 +0,0 @@
1
- import { describe, expect, it } from 'bun:test';
2
- import { shortUUID } from './shortUUID';
3
- describe('shortUUID', () => {
4
- const testUUID = '123e4567-e89b-12d3-a456-426614174000';
5
- const testShortUUID = '3fEgj34VWmVufdDCYA2MKE';
6
- it('should abbreviate a UUID to a short UUID', () => {
7
- expect(shortUUID.fromUUID(testUUID)).toBe(testShortUUID);
8
- });
9
- it('should expand a short UUID to a UUID', () => {
10
- expect(shortUUID.toUUID(testShortUUID)).toBe(testUUID);
11
- });
12
- it('should create a new UUID', () => {
13
- expect(typeof shortUUID.createUUID()).toBe('string');
14
- });
15
- it('should validate a short UUID', () => {
16
- expect(shortUUID.validate(testShortUUID)).toBe(true);
17
- expect(shortUUID.validate(testUUID)).toBe(false);
18
- });
19
- });