mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Add webhook feed method to Dispatcher
This commit is contained in:
parent
a41bccddf9
commit
3f5c51e805
4 changed files with 239 additions and 132 deletions
|
|
@ -24,6 +24,12 @@ class Request(BaseModel):
|
|||
class Config(BaseConfig):
|
||||
arbitrary_types_allowed = True
|
||||
|
||||
def render_webhook_request(self):
|
||||
return {
|
||||
"method": self.method,
|
||||
**{key: value for key, value in self.data.items() if value is not None},
|
||||
}
|
||||
|
||||
|
||||
class Response(ResponseParameters, GenericModel, Generic[T]):
|
||||
ok: bool
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue