@lokalise/connector-api-contracts 1.24.0 → 1.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/contracts/itemGroupContracts.d.ts +4 -4
- package/dist/contracts/itemGroupContracts.js +1 -1
- package/dist/contracts/itemGroupContracts.js.map +1 -1
- package/dist/contracts/itemListContracts.d.ts +2 -0
- package/dist/contracts/itemListContracts.js +10 -0
- package/dist/contracts/itemListContracts.js.map +1 -1
- package/package.json +1 -1
|
@@ -106,7 +106,7 @@ export type ItemGroupListRequestQueryString = z.infer<typeof itemGroupListReques
|
|
|
106
106
|
export declare const itemGroupEntry: z.ZodObject<{
|
|
107
107
|
id: z.ZodString;
|
|
108
108
|
name: z.ZodString;
|
|
109
|
-
parentItemGroupId: z.ZodOptional<z.ZodString
|
|
109
|
+
parentItemGroupId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
110
110
|
details: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
111
111
|
}, z.core.$strip>;
|
|
112
112
|
export type ItemGroupEntry = z.infer<typeof itemGroupEntry>;
|
|
@@ -114,7 +114,7 @@ export declare const itemGroupListResponseBody: z.ZodObject<{
|
|
|
114
114
|
items: z.ZodArray<z.ZodObject<{
|
|
115
115
|
id: z.ZodString;
|
|
116
116
|
name: z.ZodString;
|
|
117
|
-
parentItemGroupId: z.ZodOptional<z.ZodString
|
|
117
|
+
parentItemGroupId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
118
118
|
details: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
119
119
|
}, z.core.$strip>>;
|
|
120
120
|
hasMore: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -125,7 +125,7 @@ export declare const getItemGroupListContract: import("@lokalise/api-contracts")
|
|
|
125
125
|
items: z.ZodArray<z.ZodObject<{
|
|
126
126
|
id: z.ZodString;
|
|
127
127
|
name: z.ZodString;
|
|
128
|
-
parentItemGroupId: z.ZodOptional<z.ZodString
|
|
128
|
+
parentItemGroupId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
129
129
|
details: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
130
130
|
}, z.core.$strip>>;
|
|
131
131
|
hasMore: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -143,7 +143,7 @@ export declare const getItemGroupListContract: import("@lokalise/api-contracts")
|
|
|
143
143
|
items: z.ZodArray<z.ZodObject<{
|
|
144
144
|
id: z.ZodString;
|
|
145
145
|
name: z.ZodString;
|
|
146
|
-
parentItemGroupId: z.ZodOptional<z.ZodString
|
|
146
|
+
parentItemGroupId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
147
147
|
details: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
148
148
|
}, z.core.$strip>>;
|
|
149
149
|
hasMore: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -152,7 +152,7 @@ export const itemGroupListRequestQueryString = z.object({
|
|
|
152
152
|
export const itemGroupEntry = z.object({
|
|
153
153
|
id: z.string().describe('Unique item group identifier'),
|
|
154
154
|
name: z.string().max(MAX_TITLE_LENGTH).describe('Item group display name'),
|
|
155
|
-
parentItemGroupId: z.string().optional(),
|
|
155
|
+
parentItemGroupId: z.string().optional().nullable(),
|
|
156
156
|
details: z.record(z.string(), z.any()),
|
|
157
157
|
});
|
|
158
158
|
export const itemGroupListResponseBody = z
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"itemGroupContracts.js","sourceRoot":"","sources":["../../src/contracts/itemGroupContracts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAA;AACvD,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAA;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,4BAA4B,EAAE,gCAAgC,EAAE,MAAM,oBAAoB,CAAA;AACnG,OAAO,EAAE,mCAAmC,EAA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GAAG,EAAE,CAAC,iBAAiB;IACrC,WAAW,EAAE,kEAAkE;IAC/E,kBAAkB,EAAE,+BAA+B;IACnD,yBAAyB,EAAE,yBAAyB;IACpD,2BAA2B,EAAE;QAC3B,GAAG,EAAE,yBAAyB;QAC9B,GAAG,EAAE,4BAA4B;KAClC;IACD,mBAAmB,EAAE,gCAAgC;CACtD,CAAC,CAAA"}
|
|
@@ -2,6 +2,7 @@ import { z } from 'zod/v4';
|
|
|
2
2
|
export declare const itemListRequestQueryString: z.ZodObject<{
|
|
3
3
|
limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
4
4
|
cursor: z.ZodOptional<z.ZodString>;
|
|
5
|
+
contentTypes: z.ZodOptional<z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodArray<z.ZodString>>>;
|
|
5
6
|
$filter: z.ZodOptional<z.ZodString>;
|
|
6
7
|
}, z.core.$strip>;
|
|
7
8
|
export type ItemListRequestQueryString = z.infer<typeof itemListRequestQueryString>;
|
|
@@ -46,6 +47,7 @@ export declare const getItemListContract: import("@lokalise/api-contracts").GetR
|
|
|
46
47
|
}, z.core.$strip>, undefined, z.ZodObject<{
|
|
47
48
|
limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
48
49
|
cursor: z.ZodOptional<z.ZodString>;
|
|
50
|
+
contentTypes: z.ZodOptional<z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodArray<z.ZodString>>>;
|
|
49
51
|
$filter: z.ZodOptional<z.ZodString>;
|
|
50
52
|
}, z.core.$strip>, z.ZodObject<{
|
|
51
53
|
'ce-config': z.ZodString;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { paginatedResponseSchema } from '@lokalise/api-common';
|
|
2
2
|
import { buildGetRoute } from '@lokalise/api-contracts';
|
|
3
|
+
import { toArrayPreprocessor } from '@lokalise/zod-extras';
|
|
3
4
|
import { z } from 'zod/v4';
|
|
4
5
|
import { MAX_TITLE_LENGTH } from "./cacheContracts.js";
|
|
5
6
|
import { COMMON_ERROR_RESPONSE_SCHEMA, CONNECTOR_REQUEST_HEADERS_SCHEMA, ITEM_IDENTIFIER_SCHEMA, RATE_LIMIT_RESPONSE_HEADERS_SCHEMA, } from "./commonSchemas.js";
|
|
@@ -17,6 +18,15 @@ export const itemListRequestQueryString = z.object({
|
|
|
17
18
|
* For this param you are expected to pass the cursor value returned in the response to the last request.
|
|
18
19
|
*/
|
|
19
20
|
cursor: z.string().optional(),
|
|
21
|
+
/**
|
|
22
|
+
* @deprecated Use `$filter=contentType in ('article', 'page')` instead.
|
|
23
|
+
*
|
|
24
|
+
* Domain content type to filter by, e.g. "newsletters", "campaigns", "emails".
|
|
25
|
+
* In case more than one value is provided, cursor is expected to keep track of
|
|
26
|
+
* what content type it is fetching now. If not set, all supported content types
|
|
27
|
+
* will be iterated through.
|
|
28
|
+
*/
|
|
29
|
+
contentTypes: z.preprocess(toArrayPreprocessor, z.array(z.string())).optional(),
|
|
20
30
|
/**
|
|
21
31
|
* OData $filter expression for filtering items.
|
|
22
32
|
* Parsed and validated by the connector adapter.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"itemListContracts.js","sourceRoot":"","sources":["../../src/contracts/itemListContracts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAA;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAA;AACvD,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAA;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EACL,4BAA4B,EAC5B,gCAAgC,EAChC,sBAAsB,EACtB,kCAAkC,GACnC,MAAM,oBAAoB,CAAA;AAE3B,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC,MAAM,CAAC;IACjD;;;;;OAKG;IACH,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC,GAA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