mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-14 10:53:23 +00:00
Adding new code-generator (Butcher) (#1069)
* Re-generate types * Re-generate methods (only attributes) * Added enums * Base init generator * Added butcher configs * Fixed tests, bump butcher * Added changelog * Added enum docs * Added templates for docs index * Re-generate bot class, remove deprecated methods
This commit is contained in:
parent
c7779abc50
commit
d034c1ba9f
387 changed files with 32036 additions and 3144 deletions
75
.butcher/types/MessageEntity/entity.json
Normal file
75
.butcher/types/MessageEntity/entity.json
Normal file
|
|
@ -0,0 +1,75 @@
|
|||
{
|
||||
"meta": {
|
||||
"deprecated": false
|
||||
},
|
||||
"group": {
|
||||
"title": "Available types",
|
||||
"anchor": "available-types"
|
||||
},
|
||||
"object": {
|
||||
"anchor": "messageentity",
|
||||
"name": "MessageEntity",
|
||||
"description": "This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.",
|
||||
"html_description": "<p>This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.</p>",
|
||||
"rst_description": "This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.",
|
||||
"annotations": [
|
||||
{
|
||||
"type": "String",
|
||||
"description": "Type of the entity. Currently, can be 'mention' (@username), 'hashtag' (#hashtag), 'cashtag' ($USD), 'bot_command' (/start@jobs_bot), 'url' (https://telegram.org), 'email' (do-not-reply@telegram.org), 'phone_number' (+1-212-555-0123), 'bold' (bold text), 'italic' (italic text), 'underline' (underlined text), 'strikethrough' (strikethrough text), 'spoiler' (spoiler message), 'code' (monowidth string), 'pre' (monowidth block), 'text_link' (for clickable text URLs), 'text_mention' (for users without usernames), 'custom_emoji' (for inline custom emoji stickers)",
|
||||
"html_description": "<td>Type of the entity. Currently, can be “mention” (<code>@username</code>), “hashtag” (<code>#hashtag</code>), “cashtag” (<code>$USD</code>), “bot_command” (<code>/start@jobs_bot</code>), “url” (<code>https://telegram.org</code>), “email” (<code>do-not-reply@telegram.org</code>), “phone_number” (<code>+1-212-555-0123</code>), “bold” (<strong>bold text</strong>), “italic” (<em>italic text</em>), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users <a href=\"https://telegram.org/blog/edit#new-mentions\">without usernames</a>), “custom_emoji” (for inline custom emoji stickers)</td>",
|
||||
"rst_description": "Type of the entity. Currently, can be 'mention' (:code:`@username`), 'hashtag' (:code:`#hashtag`), 'cashtag' (:code:`$USD`), 'bot_command' (:code:`/start@jobs_bot`), 'url' (:code:`https://telegram.org`), 'email' (:code:`do-not-reply@telegram.org`), 'phone_number' (:code:`+1-212-555-0123`), 'bold' (**bold text**), 'italic' (*italic text*), 'underline' (underlined text), 'strikethrough' (strikethrough text), 'spoiler' (spoiler message), 'code' (monowidth string), 'pre' (monowidth block), 'text_link' (for clickable text URLs), 'text_mention' (for users `without usernames <https://telegram.org/blog/edit#new-mentions>`_), 'custom_emoji' (for inline custom emoji stickers)\n",
|
||||
"name": "type",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"type": "Integer",
|
||||
"description": "Offset in UTF-16 code units to the start of the entity",
|
||||
"html_description": "<td>Offset in <a href=\"/api/entities#entity-length\">UTF-16 code units</a> to the start of the entity</td>",
|
||||
"rst_description": "Offset in `UTF-16 code units <https://core.telegram.org/api/entities#entity-length>`_ to the start of the entity\n",
|
||||
"name": "offset",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"type": "Integer",
|
||||
"description": "Length of the entity in UTF-16 code units",
|
||||
"html_description": "<td>Length of the entity in <a href=\"/api/entities#entity-length\">UTF-16 code units</a></td>",
|
||||
"rst_description": "Length of the entity in `UTF-16 code units <https://core.telegram.org/api/entities#entity-length>`_\n",
|
||||
"name": "length",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"type": "String",
|
||||
"description": "For 'text_link' only, URL that will be opened after user taps on the text",
|
||||
"html_description": "<td><em>Optional</em>. For “text_link” only, URL that will be opened after user taps on the text</td>",
|
||||
"rst_description": "*Optional*. For 'text_link' only, URL that will be opened after user taps on the text\n",
|
||||
"name": "url",
|
||||
"required": false
|
||||
},
|
||||
{
|
||||
"type": "User",
|
||||
"description": "For 'text_mention' only, the mentioned user",
|
||||
"html_description": "<td><em>Optional</em>. For “text_mention” only, the mentioned user</td>",
|
||||
"rst_description": "*Optional*. For 'text_mention' only, the mentioned user\n",
|
||||
"name": "user",
|
||||
"required": false
|
||||
},
|
||||
{
|
||||
"type": "String",
|
||||
"description": "For 'pre' only, the programming language of the entity text",
|
||||
"html_description": "<td><em>Optional</em>. For “pre” only, the programming language of the entity text</td>",
|
||||
"rst_description": "*Optional*. For 'pre' only, the programming language of the entity text\n",
|
||||
"name": "language",
|
||||
"required": false
|
||||
},
|
||||
{
|
||||
"type": "String",
|
||||
"description": "For 'custom_emoji' only, unique identifier of the custom emoji. Use getCustomEmojiStickers to get full information about the sticker",
|
||||
"html_description": "<td><em>Optional</em>. For “custom_emoji” only, unique identifier of the custom emoji. Use <a href=\"#getcustomemojistickers\">getCustomEmojiStickers</a> to get full information about the sticker</td>",
|
||||
"rst_description": "*Optional*. For 'custom_emoji' only, unique identifier of the custom emoji. Use :class:`aiogram.methods.get_custom_emoji_stickers.GetCustomEmojiStickers` to get full information about the sticker\n",
|
||||
"name": "custom_emoji_id",
|
||||
"required": false
|
||||
}
|
||||
],
|
||||
"category": "types"
|
||||
}
|
||||
}
|
||||
2
.butcher/types/MessageEntity/replace.yml
Normal file
2
.butcher/types/MessageEntity/replace.yml
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
bases:
|
||||
- MutableTelegramObject
|
||||
Loading…
Add table
Add a link
Reference in a new issue