Skip to main content
sunpeak API

Overview

Returns a function to request the host to tear down the app. If the host approves, it will send the standard teardown signal back (triggering any useTeardown callbacks) before unmounting the iframe. This is for app-initiated close, as opposed to host-initiated teardown handled by useTeardown.

Wraps requestTeardown

MCP Apps SDK reference

Import

Signature

Returns

requestTeardown
() => Promise<void>
Function to request the host to tear down this app.

Usage