Layer 220
method Users Bots
messages.toggleSuggestedPostApproval#8107455c flags:# reject:flags.1?true peer:InputPeer msg_id:int schedule_date:flags.0?int reject_comment:flags.2?string = Updates;

Parameters

Name Type Description
Flags # Flags, see TL conditional fields
Reject flags.1?true Reject the suggested post.
Peer InputPeer Both for users and channels, must contain the ID of the direct messages monoforum (for channels, the topic ID is extracted automatically from the msg_id ).
MsgId int ID of the suggestion message.
ScheduleDate flags.0?int Custom scheduling date.
RejectComment flags.2?string Optional comment for rejections (can only be used if reject is set).

Returns

Updates

Possible Errors

Code Type Description
400 PEER_ID_INVALID The provided peer id is invalid.

Gogram Example

// MessagesToggleSuggestedPostApproval - using Params struct
result, err := client.MessagesToggleSuggestedPostApproval(&tg.MessagesToggleSuggestedPostApprovalParams{
    Peer: &tg.InputPeerUser{UserID: int64(123456789)},
    MsgId: 0,

    // Optional fields:
    // Reject: true,
    // ScheduleDate: 0,
    // RejectComment: "...",
})
if err != nil {
    // handle error
}
// result is *tg.Updates