Typed Zodios client and shared schemas for the Support API
npm install @xcelsior/support-clientTyped ts-rest contract, Axios-based client, and shared Zod schemas for the Support API.
``ts
import { createSupportClient } from '@xcelsior/support-client';
const client = createSupportClient({
baseURL: process.env.SUPPORT_API_URL!,
apiKey: process.env.SUPPORT_API_KEY!,
apiKeyHeaderName: 'x-api-key', // optional, defaults to x-api-key
});
const response = await client.getSupportConfig();
const config = response.body?.data;
`
The client returns full ts-rest responses, so each call exposes the HTTP status, typedbody, and headers metadata. Pass apiKeyHeaderName (default x-api-key) or include yourheaders` if you need a different authentication scheme.
own header via