@darco2903/cdn-api 1.1.9 → 1.2.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/client.d.ts +4 -0
- package/dist/contract/endpoint.d.ts +14 -2
- package/dist/contract/endpoint.js +4 -1
- package/dist/contract/index.d.ts +14 -2
- package/dist/uploader.d.ts +4 -0
- package/package.json +1 -1
package/dist/client.d.ts
CHANGED
|
@@ -904,6 +904,10 @@ export declare function createClient(origin: string): {
|
|
|
904
904
|
not_finite: "not_finite";
|
|
905
905
|
}>;
|
|
906
906
|
}, import("zod").ZodAny, "strip">[];
|
|
907
|
+
} | {
|
|
908
|
+
code: "BAD_REQUEST";
|
|
909
|
+
name: "APIError";
|
|
910
|
+
error: "Endpoint path is invalid";
|
|
907
911
|
};
|
|
908
912
|
headers: Headers;
|
|
909
913
|
} | {
|
|
@@ -22,7 +22,7 @@ declare const _default: {
|
|
|
22
22
|
}>;
|
|
23
23
|
responses: {
|
|
24
24
|
204: z.ZodUndefined;
|
|
25
|
-
400: z.ZodObject<{
|
|
25
|
+
400: z.ZodUnion<[z.ZodObject<{
|
|
26
26
|
name: z.ZodLiteral<"ZodError">;
|
|
27
27
|
issues: z.ZodArray<z.ZodObject<{
|
|
28
28
|
path: z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber]>, "many">;
|
|
@@ -136,7 +136,19 @@ declare const _default: {
|
|
|
136
136
|
not_finite: "not_finite";
|
|
137
137
|
}>;
|
|
138
138
|
}, z.ZodAny, "strip">[];
|
|
139
|
-
}
|
|
139
|
+
}>, z.ZodObject<{
|
|
140
|
+
code: z.ZodType<"BAD_REQUEST", z.ZodTypeDef, "BAD_REQUEST">;
|
|
141
|
+
error: z.ZodType<"Endpoint path is invalid", z.ZodTypeDef, "Endpoint path is invalid">;
|
|
142
|
+
name: z.ZodLiteral<"APIError">;
|
|
143
|
+
}, "strip", z.ZodTypeAny, {
|
|
144
|
+
code: "BAD_REQUEST";
|
|
145
|
+
name: "APIError";
|
|
146
|
+
error: "Endpoint path is invalid";
|
|
147
|
+
}, {
|
|
148
|
+
code: "BAD_REQUEST";
|
|
149
|
+
name: "APIError";
|
|
150
|
+
error: "Endpoint path is invalid";
|
|
151
|
+
}>]>;
|
|
140
152
|
401: z.ZodObject<{
|
|
141
153
|
code: z.ZodType<"UNAUTHORIZED", z.ZodTypeDef, "UNAUTHORIZED">;
|
|
142
154
|
error: z.ZodType<"Unauthorized", z.ZodTypeDef, "Unauthorized">;
|
|
@@ -15,7 +15,10 @@ export default c.router({
|
|
|
15
15
|
}),
|
|
16
16
|
responses: {
|
|
17
17
|
204: apiSuccess(z.undefined()),
|
|
18
|
-
400:
|
|
18
|
+
400: z.union([
|
|
19
|
+
ZodErrorSchema,
|
|
20
|
+
apiError(z.literal("BAD_REQUEST"), z.literal("Endpoint path is invalid")),
|
|
21
|
+
]),
|
|
19
22
|
401: apiError(z.literal("UNAUTHORIZED"), z.literal("Unauthorized")),
|
|
20
23
|
403: apiError(z.literal("FORBIDDEN"), z.literal("Forbidden")),
|
|
21
24
|
404: apiError(z.literal("NOT_FOUND"), z.literal("Record not found")),
|
package/dist/contract/index.d.ts
CHANGED
|
@@ -1737,7 +1737,7 @@ declare const _default: {
|
|
|
1737
1737
|
}>;
|
|
1738
1738
|
responses: {
|
|
1739
1739
|
204: import("zod").ZodUndefined;
|
|
1740
|
-
400: import("zod").ZodObject<{
|
|
1740
|
+
400: import("zod").ZodUnion<[import("zod").ZodObject<{
|
|
1741
1741
|
name: import("zod").ZodLiteral<"ZodError">;
|
|
1742
1742
|
issues: import("zod").ZodArray<import("zod").ZodObject<{
|
|
1743
1743
|
path: import("zod").ZodArray<import("zod").ZodUnion<[import("zod").ZodString, import("zod").ZodNumber]>, "many">;
|
|
@@ -1851,7 +1851,19 @@ declare const _default: {
|
|
|
1851
1851
|
not_finite: "not_finite";
|
|
1852
1852
|
}>;
|
|
1853
1853
|
}, import("zod").ZodAny, "strip">[];
|
|
1854
|
-
}
|
|
1854
|
+
}>, import("zod").ZodObject<{
|
|
1855
|
+
code: import("zod").ZodType<"BAD_REQUEST", import("zod").ZodTypeDef, "BAD_REQUEST">;
|
|
1856
|
+
error: import("zod").ZodType<"Endpoint path is invalid", import("zod").ZodTypeDef, "Endpoint path is invalid">;
|
|
1857
|
+
name: import("zod").ZodLiteral<"APIError">;
|
|
1858
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
1859
|
+
code: "BAD_REQUEST";
|
|
1860
|
+
name: "APIError";
|
|
1861
|
+
error: "Endpoint path is invalid";
|
|
1862
|
+
}, {
|
|
1863
|
+
code: "BAD_REQUEST";
|
|
1864
|
+
name: "APIError";
|
|
1865
|
+
error: "Endpoint path is invalid";
|
|
1866
|
+
}>]>;
|
|
1855
1867
|
401: import("zod").ZodObject<{
|
|
1856
1868
|
code: import("zod").ZodType<"UNAUTHORIZED", import("zod").ZodTypeDef, "UNAUTHORIZED">;
|
|
1857
1869
|
error: import("zod").ZodType<"Unauthorized", import("zod").ZodTypeDef, "Unauthorized">;
|
package/dist/uploader.d.ts
CHANGED