Returns the content of a Lua script source file, or the content of the file between the specified lines.

Note: For security reasons, you can not get the content of a script unless the script has been loaded by the server. If you attempt to get the content of a script that has not been loaded, the server returns the error "Source file ... has not been loaded".


Type: Synchronous

Parameter Name Description Required
File The name of the file that you want to view. You can use an absolute or relative path. Relative paths are relative to the Connector Framework Server installation folder. Required if the Session argument is not set.
First The line number of the first line to view. No
Last The line number of the last line to view. No
Session Instead of specifying the File argument, you can specify a session ID. In this case, the get-lines command returns the content of the file that contains the current function. If you set this parameter and do not specify the First and Last arguments, the server returns the section of code immediately around the current line (7 lines before the current line, and 7 lines after the current line). Required if the File argument is not set.




<autnresponse xmlns:autn="">
      <lines first="1" last="4">
        <line-1>function handler (document)</line-1> 
        <line-2>-- A Lua script that adds a field to a document</line-2> 
        <line-4>return true</line-4>