# Disconnect session

This is pre-built Action located under the Mainframe List Element Name. It instructs the Avo Assure Client to disconnect the session which is connected.

### **Syntax**

**Input:** `N/A`&#x20;

**Output:** `<Dynamic Variable>(Optional);<Dynamic Variable>(Optional)`&#x20;

<figure><img src="https://2174257472-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fk8QZzXZMIJSStKAzDSTu%2Fuploads%2F2DY3qdy0UGvKhslo7B8Q%2Fimage.png?alt=media&#x26;token=ba4e5f4d-acfb-4aef-ab29-f4690863d883" alt=""><figcaption></figcaption></figure>

### **Usecase/Example**

<figure><img src="https://2174257472-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fk8QZzXZMIJSStKAzDSTu%2Fuploads%2FOqIqNr8gA2xPYKy481nL%2Fimage.png?alt=media&#x26;token=a979dca1-a1f5-4529-9f22-9ebbd2f30a08" alt=""><figcaption></figcaption></figure>

### **Scenario**

Consider a scenario, when testing Mainframe Application sessions are often kept open for extended periods, sometimes interacting with multiple systems or databases. After completing the necessary test steps in a session, it is crucial to disconnect to ensure resources are released and that the system is in a clean state for future test executions. The **Disconnect session** keyword helps automate the disconnection process at the end of a test scenario.

### **Expected Result**

The Action needs to disconnect the session.

### **Output**

The Disconnect session Action disconnects the session.
