Layer 220
method Users
messages.requestSimpleWebView#413a3e73 flags:# from_switch_webview:flags.1?true from_side_menu:flags.2?true compact:flags.7?true fullscreen:flags.8?true bot:InputUser url:flags.3?string start_param:flags.4?string theme_params:flags.0?DataJSON platform:string = WebViewResult;

Parameters

Name Type Description
Flags # Flags, see TL conditional fields
FromSwitchWebview flags.1?true Whether the webapp was opened by clicking on the switch_webview button shown on top of the inline results list returned by messages. get Inline Bot Results.
FromSideMenu flags.2?true Set this flag if opening the Mini App from the installed side menu entry.
Compact flags.7?true Deprecated.
Fullscreen flags.8?true Requests to open the app in fullscreen mode.
Bot InputUser Bot that owns the mini app
Url flags.3?string Web app URL, if opening from a keyboard button or inline result
StartParam flags.4?string Deprecated.
ThemeParams flags.0?DataJSON Theme parameters
Platform string Short name of the application; 0-64 English letters, digits, and underscores

Returns

WebViewResult

Possible Errors

Code Type Description
400 BOT_INVALID This is not a valid bot.
400 URL_INVALID Invalid URL provided.

Gogram Example

// MessagesRequestSimpleWebView - using Params struct
result, err := client.MessagesRequestSimpleWebView(&tg.MessagesRequestSimpleWebViewParams{
    Bot: &tg.InputUserSelf{},
    Platform: "...",

    // Optional fields:
    // FromSwitchWebview: true,
    // FromSideMenu: true,
    // Compact: true,
    // Fullscreen: true,
    // ...
})
if err != nil {
    // handle error
}
// result is *tg.WebViewResult