TypeScript SDK for the Linq Partner API.
npm install @ericlewis/linq-partner-js --registry=https://npm.pkg.github.comimport { LinqPartnerClient } from "@ericlewis/linq-partner-js";
const client = new LinqPartnerClient({
apiKey: process.env.LINQ_API_KEY!
});
const chats = await client.chats.list({ from: "+12223334444" });import { verifyWebhookSignature } from "@ericlewis/linq-partner-js";
const ok = await verifyWebhookSignature({
signingSecret: process.env.LINQ_WEBHOOK_SECRET!,
payload: rawBody,
timestamp: headers["x-webhook-timestamp"],
signature: headers["x-webhook-signature"]
});npm install
npm run generate:types
npm run build
npm run test
npm run typecheckGitHub Actions runs CI on pull requests and pushes to main:
- Node 18, 20, 22
npm run typechecknpm testnpm run build
Releases are automated by .github/workflows/publish.yml.
- Update
package.jsonversion. - Commit and push to
main. - Create and push a tag that matches the version:
git tag v0.1.0
git push origin v0.1.0- Runs typecheck, tests, and build.
- Verifies tag version matches
package.jsonversion. - Publishes to GitHub Packages (
npm.pkg.github.com) as@ericlewis/linq-partner-js. - Creates a GitHub Release and uploads the packed npm artifact (
.tgz).openapi/v3-reference.yaml
- Uses
GITHUB_TOKENfor GitHub Packages publish (no npm token needed). prepublishOnlyalso enforces local safety checks before publish.