mirror of
https://github.com/yagop/node-telegram-bot-api
synced 2025-08-29 13:27:44 +00:00
doc: Document TelegramBot.errors, TelegramBot.messageTypes
This commit is contained in:
parent
49df0c6e02
commit
bbac07ad2c
@ -10,6 +10,7 @@ Added:
|
|||||||
1. Add `metadata` argument in `message` event (and
|
1. Add `metadata` argument in `message` event (and
|
||||||
friends e.g. `text`, `audio`, etc.) (#409) (by @jlsjonas, @GochoMugo)
|
friends e.g. `text`, `audio`, etc.) (#409) (by @jlsjonas, @GochoMugo)
|
||||||
1. Add support for Node.js v9 (by @GochoMugo)
|
1. Add support for Node.js v9 (by @GochoMugo)
|
||||||
|
1. Document *TelegramBot.errors*, *TelegramBot.messageTypes* (by @GochoMugo)
|
||||||
|
|
||||||
Changed:
|
Changed:
|
||||||
|
|
||||||
|
14
doc/api.md
14
doc/api.md
@ -83,6 +83,8 @@ TelegramBot
|
|||||||
* [.setStickerPositionInSet(sticker, position)](#TelegramBot+setStickerPositionInSet) ⇒ <code>Promise</code>
|
* [.setStickerPositionInSet(sticker, position)](#TelegramBot+setStickerPositionInSet) ⇒ <code>Promise</code>
|
||||||
* [.deleteStickerFromSet(sticker)](#TelegramBot+deleteStickerFromSet) ⇒ <code>Promise</code>
|
* [.deleteStickerFromSet(sticker)](#TelegramBot+deleteStickerFromSet) ⇒ <code>Promise</code>
|
||||||
* _static_
|
* _static_
|
||||||
|
* [.errors](#TelegramBot.errors) : <code>Object</code>
|
||||||
|
* [.messageTypes](#TelegramBot.messageTypes) : <code>Array.<String></code>
|
||||||
* [.Promise](#TelegramBot.Promise)
|
* [.Promise](#TelegramBot.Promise)
|
||||||
|
|
||||||
<a name="new_TelegramBot_new"></a>
|
<a name="new_TelegramBot_new"></a>
|
||||||
@ -1110,6 +1112,18 @@ Returns True on success.
|
|||||||
| --- | --- | --- |
|
| --- | --- | --- |
|
||||||
| sticker | <code>String</code> | File identifier of the sticker |
|
| sticker | <code>String</code> | File identifier of the sticker |
|
||||||
|
|
||||||
|
<a name="TelegramBot.errors"></a>
|
||||||
|
|
||||||
|
### TelegramBot.errors : <code>Object</code>
|
||||||
|
The different errors the library uses.
|
||||||
|
|
||||||
|
**Kind**: static property of <code>[TelegramBot](#TelegramBot)</code>
|
||||||
|
<a name="TelegramBot.messageTypes"></a>
|
||||||
|
|
||||||
|
### TelegramBot.messageTypes : <code>Array.<String></code>
|
||||||
|
The types of message updates the library handles.
|
||||||
|
|
||||||
|
**Kind**: static property of <code>[TelegramBot](#TelegramBot)</code>
|
||||||
<a name="TelegramBot.Promise"></a>
|
<a name="TelegramBot.Promise"></a>
|
||||||
|
|
||||||
### TelegramBot.Promise
|
### TelegramBot.Promise
|
||||||
|
@ -74,11 +74,18 @@ if (!process.env.NTBA_FIX_319) {
|
|||||||
|
|
||||||
|
|
||||||
class TelegramBot extends EventEmitter {
|
class TelegramBot extends EventEmitter {
|
||||||
|
/**
|
||||||
|
* The different errors the library uses.
|
||||||
|
* @type {Object}
|
||||||
|
*/
|
||||||
static get errors() {
|
static get errors() {
|
||||||
return errors;
|
return errors;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The types of message updates the library handles.
|
||||||
|
* @type {String[]}
|
||||||
|
*/
|
||||||
static get messageTypes() {
|
static get messageTypes() {
|
||||||
return _messageTypes;
|
return _messageTypes;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user