@orth/sdk
v0.3.1
Published
TypeScript SDK to call any API on the Orthogonal platform
Readme
@orth/sdk
TypeScript SDK to call any API on the Orthogonal platform.
Installation
npm install @orth/sdkQuick Start
import Orthogonal from "@orth/sdk";
const orthogonal = new Orthogonal({
apiKey: process.env.ORTHOGONAL_API_KEY,
});
const response = await orthogonal.run({
api: "andi",
path: "/api/v1/search",
query: { q: "what is the weather today" },
});
console.log(response.data);
console.log(response.price); // e.g., "0.01"Response
Success
{
"success": true,
"price": "0.01",
"data": { ... }
}Error
{
"success": false,
"price": "0",
"error": "API my-api not found or not active"
}License
MIT
