Skip to content

Provides functions to use Vault API from client code.

fetch: (input, init?) => Promise<Response>

Makes authorized requests to Vault API and prepends the /api prefix to the path. This is a wrapped version of JavaScript's fetch function.

string

The URL to make a request to

RequestInit

The request options

Promise<Response>

Only accepts strings as input, not URL or Request objects.

Naively prepends /api to the provided URL. For example, calling this with "http://example.com" would make a request to "/api/http://example.com".