Starting and Ending a BSP Application 
Use
URL parameters can be used to inform the BSP runtime environment to start or end a BSP application (corresponds to the OK code "/n" in SAP GUI) To do this, the
Query String parameter sap-sessioncmd is added to the URL and the HTTP request is sent to the server. Compare System-Specific URL Parameters
To be compatible with SAP Internet Transaction Server (ITS) and the Workplace, you can also use ~SAPSessionCmd.
Procedure
The following commands are supported:

To be compatible with SAP Internet Transaction Server (ITS) and the Workplace, you can also use ~SAPSessionCmd.
Example
http://myServer.sap-ag.de:1080/sap/bc/bsp/sap/it00?sap-sessioncmd=open
http://myServer.sap-ag.de:1080/sap/bc/bsp/sap/it00?sap-sessioncmd=close&sap-exiturl=http://www.sap.com
For a list of all system-specific URL parameters that can be used in the BSP application environment, see
System-Specific URL Parameters.