🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

@ai-sdk/provider-utils

Package Overview
Dependencies
Maintainers
2
Versions
114
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ai-sdk/provider-utils - npm Package Compare versions

Comparing version

to
0.0.14

12

./dist/index.js

@@ -314,2 +314,3 @@ "use strict";

var import_provider6 = require("@ai-sdk/provider");
var getOriginalFetch = () => fetch;
var postJsonToApi = async ({

@@ -321,3 +322,4 @@ url,

successfulResponseHandler,
abortSignal
abortSignal,
fetch: fetch2
}) => postToApi({

@@ -335,3 +337,4 @@ url,

successfulResponseHandler,
abortSignal
abortSignal,
fetch: fetch2
});

@@ -344,3 +347,4 @@ var postToApi = async ({

failedResponseHandler,
abortSignal
abortSignal,
fetch: fetch2 = getOriginalFetch()
}) => {

@@ -351,3 +355,3 @@ try {

);
const response = await fetch(url, {
const response = await fetch2(url, {
method: "POST",

@@ -354,0 +358,0 @@ headers: definedHeaders,

@@ -124,3 +124,3 @@ import { JSONParseError, TypeValidationError, APICallError } from '@ai-sdk/provider';

declare const postJsonToApi: <T>({ url, headers, body, failedResponseHandler, successfulResponseHandler, abortSignal, }: {
declare const postJsonToApi: <T>({ url, headers, body, failedResponseHandler, successfulResponseHandler, abortSignal, fetch, }: {
url: string;

@@ -132,2 +132,3 @@ headers?: Record<string, string | undefined> | undefined;

abortSignal?: AbortSignal | undefined;
fetch?: typeof fetch | undefined;
}) => Promise<{

@@ -137,3 +138,3 @@ value: T;

}>;
declare const postToApi: <T>({ url, headers, body, successfulResponseHandler, failedResponseHandler, abortSignal, }: {
declare const postToApi: <T>({ url, headers, body, successfulResponseHandler, failedResponseHandler, abortSignal, fetch, }: {
url: string;

@@ -148,2 +149,3 @@ headers?: Record<string, string | undefined> | undefined;

abortSignal?: AbortSignal | undefined;
fetch?: typeof fetch | undefined;
}) => Promise<{

@@ -150,0 +152,0 @@ value: T;

@@ -314,2 +314,3 @@ "use strict";

var import_provider6 = require("@ai-sdk/provider");
var getOriginalFetch = () => fetch;
var postJsonToApi = async ({

@@ -321,3 +322,4 @@ url,

successfulResponseHandler,
abortSignal
abortSignal,
fetch: fetch2
}) => postToApi({

@@ -335,3 +337,4 @@ url,

successfulResponseHandler,
abortSignal
abortSignal,
fetch: fetch2
});

@@ -344,3 +347,4 @@ var postToApi = async ({

failedResponseHandler,
abortSignal
abortSignal,
fetch: fetch2 = getOriginalFetch()
}) => {

@@ -351,3 +355,3 @@ try {

);
const response = await fetch(url, {
const response = await fetch2(url, {
method: "POST",

@@ -354,0 +358,0 @@ headers: definedHeaders,

{
"name": "@ai-sdk/provider-utils",
"version": "0.0.13",
"version": "0.0.14",
"license": "Apache-2.0",

@@ -5,0 +5,0 @@ "sideEffects": false,

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet