@mastra/schema-compat 1.4.0 → 1.4.1-alpha.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/_types/{@internal_ai-sdk-v5@0.0.96 → @internal_ai-sdk-v5@0.0.98}/dist/index.d.ts +61 -2
- package/dist/_types/{@internal_ai-v6@0.0.96 → @internal_ai-v6@0.0.98}/dist/index.d.ts +9 -1
- package/dist/esm-BG70JlG8.js +0 -2
- package/dist/esm-BQeGF7AD.cjs +0 -2
- package/dist/index.cjs +0 -2
- package/dist/index.js +0 -2
- package/dist/json-schema-DjoYhSTo.cjs +0 -2
- package/dist/json-schema-Ln9bxqtn.js +0 -2
- package/dist/json-schema-traverse-D0CId4oM.js +0 -2
- package/dist/json-schema-traverse-evfp8uQX.cjs +0 -2
- package/dist/json-schema.d.ts +2 -2
- package/dist/json-to-zod.cjs +0 -2
- package/dist/json-to-zod.js +0 -2
- package/dist/provider-compats/anthropic.d.ts +1 -1
- package/dist/provider-compats/deepseek.d.ts +1 -1
- package/dist/provider-compats/meta.d.ts +1 -1
- package/dist/schema-BbruRPhU.cjs +0 -2
- package/dist/schema-TQPB_dl2.js +0 -2
- package/dist/schema.types.d.ts +3 -3
- package/dist/standard-schema/adapters/ai-sdk.cjs +0 -2
- package/dist/standard-schema/adapters/ai-sdk.d.ts +1 -1
- package/dist/standard-schema/adapters/ai-sdk.js +0 -2
- package/dist/standard-schema/adapters/zod-v3.cjs +0 -2
- package/dist/standard-schema/adapters/zod-v3.js +0 -2
- package/dist/zod-to-json.cjs +0 -2
- package/dist/zod-to-json.js +0 -2
- package/package.json +10 -9
- package/dist/esm-BG70JlG8.js.map +0 -1
- package/dist/esm-BQeGF7AD.cjs.map +0 -1
- package/dist/index.cjs.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/json-schema/utils.d.ts.map +0 -1
- package/dist/json-schema-DjoYhSTo.cjs.map +0 -1
- package/dist/json-schema-Ln9bxqtn.js.map +0 -1
- package/dist/json-schema-traverse-D0CId4oM.js.map +0 -1
- package/dist/json-schema-traverse-evfp8uQX.cjs.map +0 -1
- package/dist/json-schema.d.ts.map +0 -1
- package/dist/json-to-zod.cjs.map +0 -1
- package/dist/json-to-zod.d.ts.map +0 -1
- package/dist/json-to-zod.js.map +0 -1
- package/dist/null-to-undefined.d.ts.map +0 -1
- package/dist/provider-compats/anthropic.d.ts.map +0 -1
- package/dist/provider-compats/deepseek.d.ts.map +0 -1
- package/dist/provider-compats/google.d.ts.map +0 -1
- package/dist/provider-compats/meta.d.ts.map +0 -1
- package/dist/provider-compats/openai-reasoning.d.ts.map +0 -1
- package/dist/provider-compats/openai.d.ts.map +0 -1
- package/dist/provider-compats/test-suite.d.ts.map +0 -1
- package/dist/schema-BbruRPhU.cjs.map +0 -1
- package/dist/schema-TQPB_dl2.js.map +0 -1
- package/dist/schema-compatibility-v3.d.ts.map +0 -1
- package/dist/schema-compatibility-v4.d.ts.map +0 -1
- package/dist/schema-compatibility.d.ts.map +0 -1
- package/dist/schema.d.ts.map +0 -1
- package/dist/schema.types.d.ts.map +0 -1
- package/dist/standard-schema/adapters/ai-sdk.cjs.map +0 -1
- package/dist/standard-schema/adapters/ai-sdk.d.ts.map +0 -1
- package/dist/standard-schema/adapters/ai-sdk.js.map +0 -1
- package/dist/standard-schema/adapters/json-schema.d.ts.map +0 -1
- package/dist/standard-schema/adapters/zod-v3.cjs.map +0 -1
- package/dist/standard-schema/adapters/zod-v3.d.ts.map +0 -1
- package/dist/standard-schema/adapters/zod-v3.js.map +0 -1
- package/dist/standard-schema/adapters/zod-v4.d.ts.map +0 -1
- package/dist/standard-schema/standard-schema.d.ts.map +0 -1
- package/dist/standard-schema/standard-schema.types.d.ts.map +0 -1
- package/dist/standard-schema-compat.d.ts.map +0 -1
- package/dist/types.d.ts.map +0 -1
- package/dist/utils.d.ts.map +0 -1
- package/dist/zod-to-json.cjs.map +0 -1
- package/dist/zod-to-json.d.ts.map +0 -1
- package/dist/zod-to-json.js.map +0 -1
- package/dist/zodTypes.d.ts.map +0 -1
- /package/dist/_types/{@internal_ai-sdk-v4@0.0.96 → @internal_ai-sdk-v4@0.0.98}/dist/index.d.ts +0 -0
- /package/dist/_types/{@internal_ai-sdk-v4@0.0.96 → @internal_ai-sdk-v4@0.0.98}/package.json +0 -0
- /package/dist/_types/{@internal_ai-sdk-v5@0.0.96 → @internal_ai-sdk-v5@0.0.98}/package.json +0 -0
- /package/dist/_types/{@internal_ai-v6@0.0.96 → @internal_ai-v6@0.0.98}/package.json +0 -0
package/dist/_types/{@internal_ai-sdk-v5@0.0.96 → @internal_ai-sdk-v5@0.0.98}/dist/index.d.ts
RENAMED
|
@@ -200,9 +200,11 @@ declare namespace _ai_sdk_provider_utils {
|
|
|
200
200
|
getRuntimeEnvironmentUserAgent,
|
|
201
201
|
injectJsonInstructionIntoMessages,
|
|
202
202
|
isAbortError,
|
|
203
|
+
isArrayBuffer,
|
|
203
204
|
isBrowserRuntime,
|
|
204
205
|
isParsableJson,
|
|
205
206
|
isSameOrigin,
|
|
207
|
+
isUint8Array,
|
|
206
208
|
isUrlSupported,
|
|
207
209
|
isValidator,
|
|
208
210
|
jsonSchema,
|
|
@@ -224,7 +226,9 @@ declare namespace _ai_sdk_provider_utils {
|
|
|
224
226
|
resolve,
|
|
225
227
|
safeParseJSON,
|
|
226
228
|
safeValidateTypes,
|
|
229
|
+
secureJsonParse,
|
|
227
230
|
standardSchemaValidator,
|
|
231
|
+
stringifyWithBigIntAndCycles,
|
|
228
232
|
tool,
|
|
229
233
|
validateDownloadUrl,
|
|
230
234
|
validateTypes,
|
|
@@ -2178,7 +2182,7 @@ declare type FetchFunction = typeof globalThis.fetch;
|
|
|
2178
2182
|
* Redirects are rejected by default. Callers using `redirect: 'manual'` must
|
|
2179
2183
|
* validate the Location target before issuing another request.
|
|
2180
2184
|
*/
|
|
2181
|
-
declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, trustedOrigin, redirect, }: {
|
|
2185
|
+
declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, trustedOrigin, redirect, requireDnsValidation, }: {
|
|
2182
2186
|
url: string | URL;
|
|
2183
2187
|
init?: RequestInit;
|
|
2184
2188
|
fetch?: FetchFunction;
|
|
@@ -2188,6 +2192,11 @@ declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, tru
|
|
|
2188
2192
|
*/
|
|
2189
2193
|
trustedOrigin?: string;
|
|
2190
2194
|
redirect?: 'error' | 'manual';
|
|
2195
|
+
/**
|
|
2196
|
+
* Reject untrusted URLs on server runtimes without a DNS-pinned default
|
|
2197
|
+
* transport unless an explicit custom fetch provides equivalent validation.
|
|
2198
|
+
*/
|
|
2199
|
+
requireDnsValidation?: boolean;
|
|
2191
2200
|
}): Promise<Response>;
|
|
2192
2201
|
|
|
2193
2202
|
/**
|
|
@@ -2199,6 +2208,12 @@ declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, tru
|
|
|
2199
2208
|
* target (e.g. an internal address) before we ever see its URL, defeating the
|
|
2200
2209
|
* SSRF guard.
|
|
2201
2210
|
*
|
|
2211
|
+
* Manually followed redirects from HTTPS to HTTP are rejected before requesting
|
|
2212
|
+
* the target.
|
|
2213
|
+
*
|
|
2214
|
+
* All caller headers except User-Agent are dropped on cross-origin redirects.
|
|
2215
|
+
* Callers must decide which credentials may be sent to the initial URL.
|
|
2216
|
+
*
|
|
2202
2217
|
* A `redirect: 'manual'` request yields an unreadable opaque response in the
|
|
2203
2218
|
* browser (and in other spec-compliant fetch implementations), so the redirect
|
|
2204
2219
|
* target cannot be validated here. In a real browser this is safe to follow
|
|
@@ -3029,13 +3044,44 @@ export declare interface GenerateTextResult<TOOLS extends ToolSet, OUTPUT> {
|
|
|
3029
3044
|
|
|
3030
3045
|
declare function getErrorMessage(error: unknown | undefined): string;
|
|
3031
3046
|
|
|
3032
|
-
declare const getFromApi: <T>({ url, headers, successfulResponseHandler, failedResponseHandler, abortSignal, fetch, }: {
|
|
3047
|
+
declare const getFromApi: <T>({ url, headers, successfulResponseHandler, failedResponseHandler, abortSignal, fetch, validateUrl, credentialedOrigin, trustedOrigin, }: {
|
|
3033
3048
|
url: string;
|
|
3034
3049
|
headers?: Record<string, string | undefined>;
|
|
3035
3050
|
failedResponseHandler: ResponseHandler<Error>;
|
|
3036
3051
|
successfulResponseHandler: ResponseHandler<T>;
|
|
3037
3052
|
abortSignal?: AbortSignal;
|
|
3038
3053
|
fetch?: FetchFunction;
|
|
3054
|
+
/**
|
|
3055
|
+
* Set `true` when `url` is untrusted (e.g. taken from a provider response
|
|
3056
|
+
* body): it is routed through {@link fetchWithValidatedRedirects}, which
|
|
3057
|
+
* rejects private/loopback/link-local targets and re-validates redirect
|
|
3058
|
+
* hops; blocked URLs throw `DownloadError`. Set `false` only for URLs built
|
|
3059
|
+
* from a developer-configured endpoint.
|
|
3060
|
+
*
|
|
3061
|
+
* Optional for backwards compatibility with existing callers; omitting it
|
|
3062
|
+
* behaves like `false` (no validation).
|
|
3063
|
+
*/
|
|
3064
|
+
validateUrl?: boolean;
|
|
3065
|
+
/**
|
|
3066
|
+
* When set, `headers` are sent only if `url` is same-origin with this origin
|
|
3067
|
+
* (the user-agent suffix is always kept). Pass the provider's configured
|
|
3068
|
+
* base URL alongside `validateUrl: true` so credentials never ride a request
|
|
3069
|
+
* to a response-supplied host on a different origin (e.g. a CDN). Redirects
|
|
3070
|
+
* that later cross origin drop all caller headers regardless (see
|
|
3071
|
+
* {@link fetchWithValidatedRedirects}).
|
|
3072
|
+
*/
|
|
3073
|
+
credentialedOrigin?: string;
|
|
3074
|
+
/**
|
|
3075
|
+
* A developer-configured origin (e.g. the provider's `baseURL`) that is
|
|
3076
|
+
* exempt from URL validation when `validateUrl` is `true`. A response URL
|
|
3077
|
+
* (or redirect hop) that is same-origin with it is fetched without target
|
|
3078
|
+
* validation — it points at exactly the host a config-derived
|
|
3079
|
+
* `validateUrl: false` request would fetch anyway, so blocking it would
|
|
3080
|
+
* only break legitimate self-hosted / localhost deployments whose response
|
|
3081
|
+
* URLs point back at the configured host. Hops on any other origin are
|
|
3082
|
+
* still validated. Must never be derived from response data.
|
|
3083
|
+
*/
|
|
3084
|
+
trustedOrigin?: string;
|
|
3039
3085
|
}) => Promise<{
|
|
3040
3086
|
value: T;
|
|
3041
3087
|
rawValue?: unknown;
|
|
@@ -3524,6 +3570,8 @@ export declare class InvalidToolInputError extends AISDKError {
|
|
|
3524
3570
|
|
|
3525
3571
|
declare function isAbortError(error: unknown): error is Error;
|
|
3526
3572
|
|
|
3573
|
+
declare function isArrayBuffer(value: unknown): value is ArrayBuffer;
|
|
3574
|
+
|
|
3527
3575
|
/**
|
|
3528
3576
|
* Returns `true` when running in a browser.
|
|
3529
3577
|
*
|
|
@@ -3585,6 +3633,8 @@ export declare function isToolOrDynamicToolUIPart<TOOLS extends UITools>(part: U
|
|
|
3585
3633
|
|
|
3586
3634
|
export declare function isToolUIPart<TOOLS extends UITools>(part: UIMessagePart<UIDataTypes, TOOLS>): part is ToolUIPart<TOOLS>;
|
|
3587
3635
|
|
|
3636
|
+
declare function isUint8Array(value: unknown): value is Uint8Array;
|
|
3637
|
+
|
|
3588
3638
|
/**
|
|
3589
3639
|
* Checks if the given URL is supported natively by the model.
|
|
3590
3640
|
*
|
|
@@ -5833,6 +5883,8 @@ export declare type Schema<OBJECT = unknown> = Validator<OBJECT> & {
|
|
|
5833
5883
|
*/
|
|
5834
5884
|
declare const schemaSymbol: unique symbol;
|
|
5835
5885
|
|
|
5886
|
+
declare function secureJsonParse(text: string): any;
|
|
5887
|
+
|
|
5836
5888
|
export declare class SerialJobExecutor {
|
|
5837
5889
|
private queue;
|
|
5838
5890
|
private isProcessing;
|
|
@@ -7548,6 +7600,13 @@ export declare type StreamTextTransform<TOOLS extends ToolSet> = (options: {
|
|
|
7548
7600
|
stopStream: () => void;
|
|
7549
7601
|
}) => TransformStream<TextStreamPart<TOOLS>, TextStreamPart<TOOLS>>;
|
|
7550
7602
|
|
|
7603
|
+
/**
|
|
7604
|
+
* Serializes a value as JSON, representing BigInt values as decimal strings and
|
|
7605
|
+
* ancestor cycles as "[Circular]". Reused objects, toJSON methods, and other JSON
|
|
7606
|
+
* serialization behavior are preserved. Getters and toJSON methods may throw.
|
|
7607
|
+
*/
|
|
7608
|
+
declare function stringifyWithBigIntAndCycles(value: unknown): string;
|
|
7609
|
+
|
|
7551
7610
|
declare const symbol$1: unique symbol;
|
|
7552
7611
|
|
|
7553
7612
|
declare const symbol$1_2: unique symbol;
|
|
@@ -3113,7 +3113,7 @@ declare type FetchFunction = typeof globalThis.fetch;
|
|
|
3113
3113
|
* Redirects are rejected by default. Callers using `redirect: 'manual'` must
|
|
3114
3114
|
* validate the Location target before issuing another request.
|
|
3115
3115
|
*/
|
|
3116
|
-
declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, trustedOrigin, redirect, }: {
|
|
3116
|
+
declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, trustedOrigin, redirect, requireDnsValidation, }: {
|
|
3117
3117
|
url: string | URL;
|
|
3118
3118
|
init?: RequestInit;
|
|
3119
3119
|
fetch?: FetchFunction;
|
|
@@ -3123,6 +3123,11 @@ declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, tru
|
|
|
3123
3123
|
*/
|
|
3124
3124
|
trustedOrigin?: string;
|
|
3125
3125
|
redirect?: 'error' | 'manual';
|
|
3126
|
+
/**
|
|
3127
|
+
* Reject untrusted URLs on server runtimes without a DNS-pinned default
|
|
3128
|
+
* transport unless an explicit custom fetch provides equivalent validation.
|
|
3129
|
+
*/
|
|
3130
|
+
requireDnsValidation?: boolean;
|
|
3126
3131
|
}): Promise<Response>;
|
|
3127
3132
|
|
|
3128
3133
|
/**
|
|
@@ -3134,6 +3139,9 @@ declare function fetchWithValidatedEndpoint({ url, init, fetch: customFetch, tru
|
|
|
3134
3139
|
* target (e.g. an internal address) before we ever see its URL, defeating the
|
|
3135
3140
|
* guard.
|
|
3136
3141
|
*
|
|
3142
|
+
* Manually followed redirects from HTTPS to HTTP are rejected before requesting
|
|
3143
|
+
* the target.
|
|
3144
|
+
*
|
|
3137
3145
|
* Request headers are also protected: {@link sanitizeRequestHeaders} strips
|
|
3138
3146
|
* proxy/metadata/cookie/hop-by-hop headers before the first request, and all
|
|
3139
3147
|
* caller headers except `User-Agent` are dropped on a cross-origin redirect.
|
package/dist/esm-BG70JlG8.js
CHANGED
|
@@ -1043,5 +1043,3 @@ const zodToJsonSchema = (schema, options) => {
|
|
|
1043
1043
|
// ../../../../../setup-pnpm/node_modules/.bin/store/v11/links/@/zod-to-json-schema/3.25.2/11b60cc1af48e6db6bae9c01d6bfb4475dbd524727905fbbc909de63613a66c9/node_modules/zod-to-json-schema/dist/esm/index.js
|
|
1044
1044
|
var esm_default = zodToJsonSchema;
|
|
1045
1045
|
export { ignoreOverride as n, esm_default as t };
|
|
1046
|
-
|
|
1047
|
-
//# sourceMappingURL=esm-BG70JlG8.js.map
|
package/dist/esm-BQeGF7AD.cjs
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -6485,5 +6485,3 @@ exports.prepareJsonSchemaForOpenAIStrictMode = require_zod_to_json.prepareJsonSc
|
|
|
6485
6485
|
exports.standardSchemaToJSONSchema = require_schema.standardSchemaToJSONSchema;
|
|
6486
6486
|
exports.toStandardSchema = require_schema.toStandardSchema;
|
|
6487
6487
|
exports.wrapSchemaWithNullTransform = wrapSchemaWithNullTransform;
|
|
6488
|
-
|
|
6489
|
-
//# sourceMappingURL=index.cjs.map
|
package/dist/index.js
CHANGED
|
@@ -6447,5 +6447,3 @@ var MetaSchemaCompatLayer = class extends SchemaCompatLayer {
|
|
|
6447
6447
|
}
|
|
6448
6448
|
};
|
|
6449
6449
|
export { ALL_ARRAY_CHECKS, ALL_NUMBER_CHECKS, ALL_STRING_CHECKS, ALL_ZOD_TYPES, AnthropicSchemaCompatLayer, DeepSeekSchemaCompatLayer, GoogleSchemaCompatLayer, JSON_SCHEMA_LIBRARY_OPTIONS, MetaSchemaCompatLayer, OpenAIReasoningSchemaCompatLayer, OpenAISchemaCompatLayer, SUPPORTED_ZOD_TYPES, SchemaCompatLayer, SchemaCompatLayer$1 as SchemaCompatLayerV3, SchemaCompatLayer$2 as SchemaCompatLayerV4, UNSUPPORTED_ZOD_TYPES, applyCompatLayer, applyOpenAICompatToTools, applyOpenAICompatTransforms, convertSchemaToZod, convertZodSchemaToAISDKSchema, ensureAllPropertiesRequired, extractZodSchema, isArr, isNumber, isObj, isOptional, isStandardJSONSchema, isStandardSchema, isStandardSchemaWithJSON, isString, isUnion, isZodType, jsonSchema, prepareJsonSchemaForOpenAIStrictMode, standardSchemaToJSONSchema, toStandardSchema, wrapSchemaWithNullTransform };
|
|
6450
|
-
|
|
6451
|
-
//# sourceMappingURL=index.js.map
|
package/dist/json-schema.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { jsonSchema } from './_types/@internal_ai-sdk-v4@0.0.
|
|
2
|
-
export type { Schema } from './_types/@internal_ai-sdk-v4@0.0.
|
|
1
|
+
export { jsonSchema } from './_types/@internal_ai-sdk-v4@0.0.98/dist/index.js';
|
|
2
|
+
export type { Schema } from './_types/@internal_ai-sdk-v4@0.0.98/dist/index.js';
|
|
3
3
|
export type { JSONSchema7 } from './_types/@types_json-schema@7.0.15/index.js';
|
|
4
4
|
//# sourceMappingURL=json-schema.d.ts.map
|
package/dist/json-to-zod.cjs
CHANGED
package/dist/json-to-zod.js
CHANGED
|
@@ -821,5 +821,3 @@ function jsonSchemaToZod(schema, options = {}) {
|
|
|
821
821
|
}).replace(/\.reduce<[^>]+>/g, ".reduce");
|
|
822
822
|
}
|
|
823
823
|
export { addJsdocs, expandJsdocs, half, its, jsonSchemaToZod, omit, parseAllOf, parseAnyOf, parseArray, parseBoolean, parseConst, parseDefault, parseEnum, parseIfThenElse, parseMultipleType, parseNot, parseNull, parseNullable, parseNumber, parseObject, parseOneOf, parseSchema, parseSimpleDiscriminatedOneOf, parseString, withMessage };
|
|
824
|
-
|
|
825
|
-
//# sourceMappingURL=json-to-zod.js.map
|
|
@@ -13,7 +13,7 @@ export declare class AnthropicSchemaCompatLayer extends SchemaCompatLayer {
|
|
|
13
13
|
processToJSONSchema(schema: PublicSchema<any>, io?: 'input' | 'output'): JSONSchema7;
|
|
14
14
|
shouldApply(): boolean;
|
|
15
15
|
processZodType(value: ZodType): ZodType;
|
|
16
|
-
processToAISDKSchema(zodSchema: ZodTypeV3 | ZodTypeV4): import("../_types/@internal_ai-sdk-v4@0.0.
|
|
16
|
+
processToAISDKSchema(zodSchema: ZodTypeV3 | ZodTypeV4): import("../_types/@internal_ai-sdk-v4@0.0.98/dist/index.js").Schema<unknown>;
|
|
17
17
|
processToCompatSchema<T>(schema: PublicSchema<T>): StandardSchemaWithJSON<T>;
|
|
18
18
|
preProcessJSONNode(schema: JSONSchema7): void;
|
|
19
19
|
postProcessJSONNode(schema: JSONSchema7): void;
|
|
@@ -13,7 +13,7 @@ export declare class DeepSeekSchemaCompatLayer extends SchemaCompatLayer {
|
|
|
13
13
|
shouldApply(): boolean;
|
|
14
14
|
processZodType(value: ZodTypeV3): ZodTypeV3;
|
|
15
15
|
processZodType(value: ZodTypeV4): ZodTypeV4;
|
|
16
|
-
processToAISDKSchema(zodSchema: ZodTypeV3 | ZodTypeV4): import("../_types/@internal_ai-sdk-v4@0.0.
|
|
16
|
+
processToAISDKSchema(zodSchema: ZodTypeV3 | ZodTypeV4): import("../_types/@internal_ai-sdk-v4@0.0.98/dist/index.js").Schema<any>;
|
|
17
17
|
processToCompatSchema<T>(schema: PublicSchema<T>): StandardSchemaWithJSON<T>;
|
|
18
18
|
preProcessJSONNode(schema: JSONSchema7): void;
|
|
19
19
|
postProcessJSONNode(schema: JSONSchema7): void;
|
|
@@ -13,7 +13,7 @@ export declare class MetaSchemaCompatLayer extends SchemaCompatLayer {
|
|
|
13
13
|
shouldApply(): boolean;
|
|
14
14
|
processZodType(value: ZodTypeV3): ZodTypeV3;
|
|
15
15
|
processZodType(value: ZodTypeV4): ZodTypeV4;
|
|
16
|
-
processToAISDKSchema(zodSchema: ZodTypeV3 | ZodTypeV4): import("../_types/@internal_ai-sdk-v4@0.0.
|
|
16
|
+
processToAISDKSchema(zodSchema: ZodTypeV3 | ZodTypeV4): import("../_types/@internal_ai-sdk-v4@0.0.98/dist/index.js").Schema<any>;
|
|
17
17
|
processToCompatSchema<T>(schema: PublicSchema<T>): StandardSchemaWithJSON<T>;
|
|
18
18
|
preProcessJSONNode(schema: JSONSchema7): void;
|
|
19
19
|
postProcessJSONNode(schema: JSONSchema7): void;
|
package/dist/schema-BbruRPhU.cjs
CHANGED
package/dist/schema-TQPB_dl2.js
CHANGED
|
@@ -255,5 +255,3 @@ function standardSchemaToJSONSchema(schema, options = {}) {
|
|
|
255
255
|
return jsonSchema;
|
|
256
256
|
}
|
|
257
257
|
export { standardSchemaToJSONSchema as a, isStandardSchemaWithJSON as i, isStandardJSONSchema as n, toStandardSchema as o, isStandardSchema as r, JSON_SCHEMA_LIBRARY_OPTIONS as t };
|
|
258
|
-
|
|
259
|
-
//# sourceMappingURL=schema-TQPB_dl2.js.map
|
package/dist/schema.types.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { Schema as SchemaV4 } from './_types/@internal_ai-sdk-v4@0.0.
|
|
2
|
-
import type { Schema as SchemaV5 } from './_types/@internal_ai-sdk-v5@0.0.
|
|
3
|
-
import type { Schema as SchemaV6 } from './_types/@internal_ai-v6@0.0.
|
|
1
|
+
import type { Schema as SchemaV4 } from './_types/@internal_ai-sdk-v4@0.0.98/dist/index.js';
|
|
2
|
+
import type { Schema as SchemaV5 } from './_types/@internal_ai-sdk-v5@0.0.98/dist/index.js';
|
|
3
|
+
import type { Schema as SchemaV6 } from './_types/@internal_ai-v6@0.0.98/dist/index.js';
|
|
4
4
|
import type { JSONSchema7 } from './_types/@types_json-schema@7.0.15/index.js';
|
|
5
5
|
import type z3 from 'zod/v3';
|
|
6
6
|
import type z4 from 'zod/v4';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Schema } from '../../_types/@internal_ai-v6@0.0.
|
|
1
|
+
import type { Schema } from '../../_types/@internal_ai-v6@0.0.98/dist/index.js';
|
|
2
2
|
import type { JSONSchema7 } from '../../_types/@types_json-schema@7.0.15/index.js';
|
|
3
3
|
import type { StandardSchemaWithJSON, StandardSchemaWithJSONProps } from '../standard-schema.types.js';
|
|
4
4
|
/**
|
package/dist/zod-to-json.cjs
CHANGED
|
@@ -338,5 +338,3 @@ exports.ensureAllPropertiesRequired = ensureAllPropertiesRequired;
|
|
|
338
338
|
exports.patchRecordSchemas = patchRecordSchemas;
|
|
339
339
|
exports.prepareJsonSchemaForOpenAIStrictMode = prepareJsonSchemaForOpenAIStrictMode;
|
|
340
340
|
exports.zodToJsonSchema = zodToJsonSchema;
|
|
341
|
-
|
|
342
|
-
//# sourceMappingURL=zod-to-json.cjs.map
|
package/dist/zod-to-json.js
CHANGED
package/package.json
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/schema-compat",
|
|
3
|
-
"version": "1.4.0",
|
|
3
|
+
"version": "1.4.1-alpha.0",
|
|
4
4
|
"description": "Tool schema compatibility layer for Mastra.ai",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
8
8
|
"files": [
|
|
9
|
-
"dist"
|
|
9
|
+
"dist",
|
|
10
|
+
"!dist/**/*.d.*ts.map"
|
|
10
11
|
],
|
|
11
12
|
"exports": {
|
|
12
13
|
".": {
|
|
@@ -117,13 +118,13 @@
|
|
|
117
118
|
"zod-from-json-schema-v3": "npm:zod-from-json-schema@^0.0.5",
|
|
118
119
|
"zod-to-json-schema": "^3.25.2",
|
|
119
120
|
"zod-v3": "npm:zod@^3.25.76",
|
|
120
|
-
"@internal/ai-sdk-v4": "0.0.
|
|
121
|
-
"@internal/ai-sdk-v5": "0.0.
|
|
122
|
-
"@internal/ai-v6": "0.0.
|
|
123
|
-
"@internal/lint": "0.0.
|
|
124
|
-
"@internal/llm-recorder": "0.0.
|
|
125
|
-
"@internal/test-utils": "0.0.
|
|
126
|
-
"@internal/types-builder": "0.0.
|
|
121
|
+
"@internal/ai-sdk-v4": "0.0.98",
|
|
122
|
+
"@internal/ai-sdk-v5": "0.0.98",
|
|
123
|
+
"@internal/ai-v6": "0.0.98",
|
|
124
|
+
"@internal/lint": "0.0.151",
|
|
125
|
+
"@internal/llm-recorder": "0.0.87",
|
|
126
|
+
"@internal/test-utils": "0.0.87",
|
|
127
|
+
"@internal/types-builder": "0.0.126"
|
|
127
128
|
},
|
|
128
129
|
"homepage": "https://mastra.ai",
|
|
129
130
|
"repository": {
|