yousign
v0.0.0
Published
Type-safe Javascript HTTP client for interacting with Yousign API
Downloads
153
Readme
A light-weight and type-safe HTTP client for Yousign API
Introduction
This is an unofficial, light-weight and type-safe HTTP client for the Yousign API for JavaScript.
Types are generated automatically using openapi-typescript.
[!IMPORTANT] This is an unofficial library DO NOT contact Yousign if you have have any issues using this library.
Installation
Install the package using your favorite package manager.
npm install yousignOptionally, add the following to your tsconfig.json to boost type safety:
{
"compilerOptions": {
"noUncheckedIndexedAccess": true
}
}Usage
import { createYousignClient } from "yousign";
const client = createYousignClient({ apiKey: process.env.YOUSIGN_API_KEY });
const { data, error } = await client.POST("/signature_requests", {
body: {
name: "Signature request example",
delivery_mode: "email",
timezone: "Europe/Paris",
},
});[!TIP] You can refer to the openapi-fetch documentation for more information (middlewares, options, testing, etc).
