trieve-ts-sdk
Advanced tools
Comparing version 0.0.46 to 0.0.47
@@ -35,2 +35,3 @@ import type { $OpenApiTs } from "./types.gen"; | ||
organizationId?: string; | ||
omitCredentials?: boolean; | ||
} | ||
@@ -42,2 +43,3 @@ export declare class TrieveFetchClient { | ||
organizationId?: string; | ||
omitCredentials?: boolean; | ||
constructor(opts: TrieveOpts); | ||
@@ -44,0 +46,0 @@ fetch<EJECT extends EjectOption = false, URQ = EJECT extends "eject" ? EjectedRequestBase<any> : never, URE = EJECT extends "eject" ? unknown : never, P extends Paths = Paths, M extends EJECT extends false ? MethodsForPath<P> & HttpMethod : any = MethodsForPath<P> & HttpMethod>(path: P, method: EJECT extends false ? M : HttpMethod, params?: EJECT extends false ? RequestParams<P, M> : URQ, signal?: AbortSignal): Promise<EJECT extends false ? ResponseBody<P, M> : URE>; |
@@ -25,2 +25,3 @@ var __defProp = Object.defineProperty; | ||
organizationId; | ||
omitCredentials; | ||
constructor(opts) { | ||
@@ -31,2 +32,3 @@ this.apiKey = opts.apiKey; | ||
this.organizationId = opts.organizationId; | ||
this.omitCredentials = opts.omitCredentials; | ||
} | ||
@@ -73,3 +75,3 @@ async fetch(path, method, params, signal) { | ||
const response = await fetch(this.baseUrl + updatedPath, { | ||
credentials: "omit", | ||
credentials: this.omitCredentials ? "omit" : "include", | ||
method, | ||
@@ -76,0 +78,0 @@ headers, |
@@ -9,3 +9,3 @@ { | ||
], | ||
"version": "0.0.46", | ||
"version": "0.0.47", | ||
"license": "MIT", | ||
@@ -12,0 +12,0 @@ "scripts": { |
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 too big to display
Sorry, the diff of this file is not supported yet
524500
8630