Browse docs
What's available#
Generate a client from the document#
Import the document into Postman or Insomnia to explore the API interactively, or point a standard OpenAPI code generator (openapi-generator, openapi-typescript, kiota) at it to produce a typed client in Python, Go, Java or any other supported language. The document declares the security schemes. Generators differ in how they use them, so check that your client sends Authorization: Bearer <key>.
openapi-generator-cli generate \
-i https://skedcast.com/openapi.json \
-g python \
-o ./skedcast-clientA typed TypeScript client#
openapi-typescript turns the document into types, and openapi-fetch uses them to type every call, including the required Idempotency-Key header.
npm install openapi-fetch
npm install --save-dev openapi-typescript
npx openapi-typescript https://skedcast.com/openapi.json -o ./skedcast.d.tsimport createClient from "openapi-fetch";
import type { paths } from "./skedcast";
const client = createClient<paths>({
baseUrl: "https://api.skedcast.com/v1",
headers: { Authorization: `Bearer ${process.env.SKEDCAST_API_KEY ?? ""}` },
});
const { data, error } = await client.POST("/posts", {
params: { header: { "Idempotency-Key": crypto.randomUUID() } },
body: {
clientId: "<clientId>",
content: "Hello from a generated client",
targets: { mode: "selection", accountIds: ["<accountId>"] },
schedule: { type: "at", scheduledAt: "2030-01-15T15:00:00Z" },
},
});
if (error !== undefined) {
throw new Error(`SkedCast refused the post: ${JSON.stringify(error)}`);
}
console.log(data);FAQ
- Does the OpenAPI document match the live API?
- It describes the same /v1 operations as the API reference at /developers/api-reference. Import it into Postman, Insomnia or a code generator for a client that matches the API. Regenerate the client when you want new fields.
- Is there an official SDK for my language?
- SkedCast does not publish language-specific libraries. Call the REST API directly, or generate a typed client from the OpenAPI 3.1 document in any language the generator supports.