@telegram.ts/types 1.3.1 → 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -1
- package/package.json +2 -2
- package/src/index.js +5 -2
- package/src/manageTypes.d.ts +4 -4
package/README.md
CHANGED
|
@@ -5,10 +5,13 @@ The `@telegram.ts/types` package provides comprehensive type declarations for th
|
|
|
5
5
|
This package is designed to simplify the development of Telegram bots using `telegramsjs` by providing accurate type annotations for all API methods and objects. It does not contain any executable code.
|
|
6
6
|
|
|
7
7
|
Key Features:
|
|
8
|
+
|
|
8
9
|
- Type annotations for all API methods and objects
|
|
9
10
|
- Consistent with the Telegram Bot API documentation
|
|
10
11
|
- Simplifies handling of JSON-serialized objects
|
|
11
12
|
- Customization support for InputFile handling
|
|
12
13
|
- Maintained and updated in sync with the Telegram Bot API
|
|
13
14
|
|
|
14
|
-
Join the `telegramsjs` community and make building Telegram bots even easier with `@telegram.ts/types`!
|
|
15
|
+
Join the `telegramsjs` community and make building Telegram bots even easier with `@telegram.ts/types`!
|
|
16
|
+
|
|
17
|
+
`@telegram.ts/types` is based on the source code of [@grammyjs/types](https://www.npmjs.com/package/@grammyjs/types?activeTab=readme), with proper attribution and adherence to the original author's licensing terms.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@telegram.ts/types",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.2",
|
|
4
4
|
"description": "@telegram.ts/types: Comprehensive Type Declarations for Telegram Bot API with telegramsjs",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"types": "src/index.d.ts",
|
|
@@ -23,4 +23,4 @@
|
|
|
23
23
|
"src/*.d.ts",
|
|
24
24
|
"src/index.js"
|
|
25
25
|
]
|
|
26
|
-
}
|
|
26
|
+
}
|
package/src/index.js
CHANGED
|
@@ -1,2 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
/**
|
|
2
|
+
* @telegram.ts/types is based on the source code of @grammyjs/types, with proper attribution and adherence to the original author's licensing terms.
|
|
3
|
+
* github - https://github.com/grammyjs/types
|
|
4
|
+
* npm - https://www.npmjs.com/package/@grammyjs/types?activeTab=readme
|
|
5
|
+
*/
|
package/src/manageTypes.d.ts
CHANGED
|
@@ -11,15 +11,15 @@ export interface WebhookInfo {
|
|
|
11
11
|
/** Currently used webhook IP address */
|
|
12
12
|
ip_address?: string;
|
|
13
13
|
/** Unix time for the most recent error that happened when trying to deliver an update via webhook */
|
|
14
|
-
last_error_date
|
|
14
|
+
last_error_date?: number;
|
|
15
15
|
/** Error message in human-readable format for the most recent error that happened when trying to deliver an update via webhook */
|
|
16
|
-
last_error_message
|
|
16
|
+
last_error_message?: string;
|
|
17
17
|
/** Unix time of the most recent error that happened when trying to synchronize available updates with Telegram datacenters */
|
|
18
18
|
last_synchronization_error_date?: number;
|
|
19
19
|
/** The maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery */
|
|
20
|
-
max_connections
|
|
20
|
+
max_connections?: number;
|
|
21
21
|
/** A list of update types the bot is subscribed to. Defaults to all update types except chat_member */
|
|
22
|
-
allowed_updates
|
|
22
|
+
allowed_updates?: Array<Exclude<keyof Update, "update_id">>;
|
|
23
23
|
}
|
|
24
24
|
/** This object represents a Telegram user or bot. */
|
|
25
25
|
export interface User {
|