Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork2
Typescript library for the Patreon V2 API
License
ghostrider-05/patreon-api.ts
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
Typescript oauth library for theV2 Patreon API with:
- Support for Creator access tokens and oauth tokens
- Client with methods for calling every endpoint, both resource and webhook endpoints
- Methods to create a webhook server
- Typescript types that strongly reflect your query for raw or simplified responses
constquery=QueryBuilder.campaign.setAttributes({campaign:['patron_count']})constpayload=awaitclient.fetchCampaign('campaign_id',query)// ^? { data: { attributes: { patron_count: number }}, ...}constcampaign=awaitclient.simplified.fetchCampaign('campaign_id',query)// ^? { patronCount: number, id: string, type: Type.Campaign }
npm install patreon-api.tspnpm add patreon-api.tsyarn add patreon-api.ts
Supported Patreon api: v2
The default API version for this package is2 and might change in major versions.
[!CAUTION]This package does not include v1 of the Patreon API and starts withAPI v2. The sections in the Patreon documentation are prefixed by
APIv2:. The Oauth flow, introduction andsections below sorting are related to all versions.
When the default API version is changed, old versions will still receive updates.You can not import this module by API version since it is unlikely that Patreon will release a new version any time soon.
To read more about how to use this library, go to thedocumentation. Still doubting if this library has everything you need related to the Patreon API?Compare all libraries yourself.
Compatibility
To check for compatibility with this package, look if your platform:
- has the globals:
AbortController,setTimeout,clearTimeout,setInterval,clearInterval,Request,fetch,URLandURLSearchParams- for node.js:
v22or higher - for Cloudflare workers:enable Node.js
- for node.js:
- supports
ES2020 - supports the
node:cryptomodule:createHmacandrandomUUID
This library is used to create the Patreon OpenAPI schemas for thepatreon-api-spec repository.
- Commonly used routes andcommunity apps
- Example webhook server:Cloudflare worker andexpress.js server
- Example Node.js server:ESM andCJS
Detailed changes are listed for each release inthe changelog.
For upcoming releases, seethe roadmap for planned changes.
See thecode of conduct and thecontributing guide for how to contribute. You can also support the development by writing guides, posts and templates orby funding the maintainers.
Do you have a question about using this library?Open a Q&A discussion on GitHub.
Copyright (c) 2023-present, ghostrider-05
About
Typescript library for the Patreon V2 API
Topics
Resources
License
Code of conduct
Contributing
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Sponsor this project
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Contributors6
Uh oh!
There was an error while loading.Please reload this page.