tab_close
Close the active TradingView chart tab. Optionally verify the tab title first, and choose to discard unsaved layout changes if confirmation is needed.
Instructions
Close the currently active chart tab. Names the tab it is about to close and refuses when no tab is marked active. Closing a chart tab cannot be undone through this API, so pass expect_title when it matters which one goes.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| expect_title | No | The active tab title must contain this, otherwise nothing is closed. Use tab_list first to see the titles. | |
| discard_unsaved | No | Answer TradingView unsaved-layout-changes dialog with "Close without saving" and LOSE those changes. Without this the tab stays open and the dialog is dismissed. "Save and close" is never clicked for you. |