SDKs

Official SDKs

Thin, dependency-light clients generated from the OpenAPI document, with typed responses, cursor pagination helpers, timeouts, retries on 429 and 5xx (honouring Retry-After) and typed errors.

TypeScript / JavaScript

Package: @peptide-library/sdk (publishing soon). Node 18+, Deno, Bun and edge runtimes (uses fetch). Keep the key on your server.

npm install @peptide-library/sdk

import { PeptideLibrary } from '@peptide-library/sdk';

const pl = new PeptideLibrary({ apiKey: process.env.PEPTIDE_LIBRARY_API_KEY });
const peptide = await pl.peptides.get('bpc-157');
for await (const offer of pl.prices.list({ peptide: 'bpc-157', currency: 'USD' })) {
  console.log(offer.vendor.name, offer.price);
}

Python

Package: peptide-library (publishing soon). Python 3.9+, synchronous and async clients (httpx), type hints throughout.

pip install peptide-library

from peptide_library import PeptideLibrary

pl = PeptideLibrary(api_key=os.environ.get("PEPTIDE_LIBRARY_API_KEY"))
peptide = pl.peptides.get("bpc-157")
for offer in pl.prices.list(peptide="bpc-157", currency="USD"):
    print(offer["vendor"]["name"], offer["price"])

Other languages

Generate a client from the OpenAPI 3.1 document with your favourite generator, or call the API directly: see the examples. Source, issues and changelog: public repository coming soon.