tipcc-api
v1.0.6
Published
tip.cc API Client
Readme
tip.cc API Client for Java- and Typescript-based projects
| Param | Type | Description |
| ----------------------- | -------- | --------------------------------------------------------------------------- |
| token | string | The tip.cc API token of your bot. |
| options | object | Options for the client. |
| options.baseUrl | string | The base url of the tip.cc API. |
| options.pollingInterval | number | The interval in which the client polls the tip.cc API for new transactions. |
| Param | Type | Description |
| -------- | --------------------- | -------------------------------------------------- |
| event | 'tip', 'ready' | The event to listen for. |
| callback | (data: any) => void | The callback to execute when the event is emitted. |
| Param | Type | Description |
| ----- | --------- | ---------------------------------------- |
| cache | boolean | Whether to use the cache for the result. |
| Param | Type | Description |
| ----- | --------- | ---------------------------------------- |
| cache | boolean | Whether to use the cache for the result. |
| Param | Type | Description |
| -------------- | -------- | -------------------------------------------------- |
| options | object | Options for the request. |
| options.types | 'tip' | The maximum amount of transactions to return. |
| options.since | Date | The timestamp of the oldest transaction to return. |
| options.until | Date | The timestamp of the newest transaction to return. |
| options.limit | number | The maximum amount of transactions to return. |
| options.offset | number | The offset of the transactions to return. |
TipccClient#getExchangeRates (Method)
Obtain the exchange rates for all tip.cc crypto currencies
| Param | Type | Description | | ----- | ---- | ----------- |
TipccClient#getExchangeRate (Method)
Obtain the exchange rate for a specific tip.cc crypto currency
| Param | Type | Description |
| ------------ | -------- | -------------------------------- |
| currencyCode | string | The code of the crypto currency. |
TipccClient#getTransaction (Method)
Get a specific transaction by its ID
| Param | Type | Description |
| ----- | -------- | -------------------------- |
| id | string | The ID of the transaction. |
TipccClient#postTip (Method)
Create a tip
| Param | Type | Description |
| ----------------------- | --------- | ------------------------- |
| options | object | Options for the request. |
| options.service | discord | The service to tip on. |
| options.recipient | string | The recipient of the tip. |
| options.amount.value | string | The amount of the tip. |
| options.amount.currency | string | The currency of the tip. |
TipccClient#getWallet (Method)
Get a specific wallet (Client Balance)
| Param | Type | Description |
| -------- | --------- | ----------------------------------------------------------------------- |
| currency | string | The currency of the wallet. |
| fallback | boolean | Whether to fallback to a 0-value USD wallet if the wallet doesn't exist |
TipccClient#getWallets (Method)
Get all wallets (Client Balances)
| Param | Type | Description | | ----- | ---- | ----------- |
The author is not responsible for any loss which has been made through possible vulnerabilities. If you find one open a Github Issue (Critical Vulnerabilites via Discord to Walledgarden#0002 or via Email to [email protected])
Special thanks to oknu#7863 who made the first version of the event emitter, which is heavily recycled in this repository, and the tip.cc discord bot, which makes it really easy to use crypto currency on discord, with having a wallet connected to your user account 🐻
