EditStory
---functions--- stories.editStory#2c63a72b peer:InputPeer id:int media:flags.0?InputMedia media_areas:flags.3?Vector<MediaArea> caption:flags.1?string entities:flags.1?Vector<MessageEntity> privacy_rules:flags.2?Vector<InputPrivacyRule> music:flags.4?InputDocument = Updates
Returns
| Updates |
Parameters
| peer | InputPeer | required |
| id | int | required |
| media | InputMedia | optional |
| media_areas | Vector<MediaArea> | optional |
| caption | string | optional |
| entities | Vector<MessageEntity> | optional |
| privacy_rules | Vector<InputPrivacyRule> | optional |
| music | InputDocument | optional |
Example
The examples below use placeholder values. Replace them with real data before running the code.
▶ Minimal
import asyncio
from ferogram import Client
app = Client("my_session", api_id=12345, api_hash="0123456789abcdef0123456789abcdef")
async def main():
await app.start()
result = await app.raw.stories.EditStory(
peer='username',
id=42
)
print(result)
asyncio.run(main())
The minimal example uses Ferogram's raw proxy shorthand. Peers can be passed as strings and required primitives get safe defaults. Expand Full API to see every parameter.
▶ Full API
import asyncio
from ferogram import Client, raw
app = Client("my_session", api_id=12345, api_hash="0123456789abcdef0123456789abcdef")
async def main():
await app.start()
result = await app(raw.functions.stories.EditStory(
peer=raw.types.InputPeerSelf(),
id=42,
media=raw.types.InputMediaEmpty(),
media_areas=[raw.types.MediaArea()],
caption='some string here',
entities=[raw.types.MessageEntityUnknown(offset=0, length=1)],
privacy_rules=[raw.types.InputPrivacyValueAllowAll()],
music=raw.types.InputDocumentEmpty()
))
print(result)
asyncio.run(main())