Available methods

editStory()

Edits a story previously posted by the bot on behalf of a managed business account. Requires the can_manage_stories business bot right. Returns Story on success.

parameters

parametertyperequireddescription
business_connection_idstringrequiredUnique identifier of the business connection
story_idnumberrequiredUnique identifier of the story to edit
contentInputStoryContentrequiredContent of the story
captionstringoptionalCaption of the story, 0-2048 characters after entities parsing
parse_modestringoptionalMode for parsing entities in the story caption. See formatting options for more details.
caption_entitiesMessageEntity[]optionalA JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
areasStoryArea[]optionalA JSON-serialized list of clickable areas to be shown on the story

returns

Story

usage in yaebal

not (yet) hard-typed on Api — call it through the generic .call<T>() escape hatch documented in @yaebal/types.

bot.ts
import type { EditStoryParams, Story } from "@yaebal/types";

await bot.api.call<Story>("editStory", {
  business_connection_id: "...",
  story_id: 1,
  content: {} /* InputStoryContent */,
} satisfies EditStoryParams);