Specifying the application language
Adding and deleting users/roles
You can use URL to work with JReport Server, for example, add and delete users/roles in the server security system, delete a resource node from the server resource tree, get the version table of a resource and so on. Appendix 1: URL Properties lists the properties you would need in the URL.
You can view the report results that are generated when advanced running or scheduling reports to publish to the versioning system via URL by either of the following two ways.
http://localhost:8888/webos/app/pagestudio/run.jsp?jrs.resource_path=%2fUSERFOLDERPATH%2fadmin&jrs.file=1980996366.rsdjrs.rst_version together with one of the three properties: jrs.version_id, jrs.report and jrs.result. JReport will search for the three properties one by one starting from the first to the third until it finds one.
URL Example: http://localhost:8888/webos/app/pagestudio/run.jsp?jrs.rst_version=1&jrs.report=%2fSampleReports%2fInvoice Report.cls&type=rstfile&jrs.path=%2fSampleReports%2fInvoice Report.cls&jrs.version_id=257
http://localhost:8888/jinfonet/viewVersion.jsp?jrs.cmd=jrs.view_ver_rst&jrs.result_type=2&jrs.version_number=1&jrs.ver_suff=.rst&jrs.result=%2fUSERFOLDERPATH%2fadmin%2fBanded_Link&jrs.path=%2fUSERFOLDERPATH%2fadmin%2fBanded_LinkURL Format: http://HOST:PORT/jrserver/REPORT?jrs.cmd=jrs.view_ver_rst&jrs.hist_file=RESULT_VERSION_FILE_NAME
      URL Example: http://localhost:8888/jrserver/SampleReports/SampleReports.cat/Invoice Report.cls?jrs.cmd=jrs.view_ver_rst&jrs.hist_file=1%2fadmin567625353%2f2109098280.pdf
For details about the properties that would be included in the URL, see Properties for viewing report results.
When accessing the JReport Console page or Page Report Studio UI via URL, you can control the language that is applied by setting the property jrs.language. The format of the URL is as follows:
http://HOST:PORT/CONTEXT/PAGE?PROPERTY=VALUE&jrs.language=LANGUAGE_NAME
The value of jrs.language should be the same as the language package folder name in the <server_install_root>\resources\server\languages directory and be lower-case letters.
The following are two examples:
http://127.0.0.1:8888/jinfonet/index.jsp?jrs.language=zh-cn
http://127.0.0.1:8888/webos/app/pagestudio/run.jsp?jrs.report=/SampleReports/Invoice Report.cls&jrs.catalog=/SampleReports/SampleReports.cat&jrs.cat_version=1&jrs.path=/SampleReports/Invoice Report.cls&jrs.language=zh-cn
Admin users can run the following JSPs to add or remove users/roles to the security system on JReport Server. However, before they can do this, they should have logged onto the JReport Server administration console in order to run the URL successfully.
Description: Adds a new user.
        URL Example: http://localhost:8889/admin/security/processNewUser.jsp?currentEditRealm=defaultRealm&user=Dean&fullName=Dean%20Black&description=Product%20Manager%20&email=Dean@jinfonet.com&password=123456&confirmPassword=123456&passwordLife=expire&expireTime=25&enableBlank=blank&minLength=6&jrs.privilege_access_advanced_properties=true
Description: Deletes a specific user.
        URL Example: http://localhost:8889/admin/security/processRemoveUser.jsp?currentEditRealm=defaultRealm&userName=testurl
Description: Adds a new role.
        URL Example: http://localhost:8889/admin/security/processNewRole.jsp?currentEditRealm=defaultRealm&roleName=role1&parentRoles=NoneParent&description=TWD&jrs.privilege_publish_report=true
Description: Deletes a specific role.
        URL Example: http://localhost:8889/admin/security/processRemoveRole.jsp?currentEditRealm=defaultRealm&roleName=role1
For details about the properties that would be included in the URL, see Properties for adding and deleting users/roles.
Description: Gets all resource nodes (folder, catalog, report and result) of a folder.
    HTTP Method: GET/POST
    URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_cat_rpts_new&jrs.path=RESOURCENODE
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_cat_rpts_new&jrs.path=/SampleReports
    Response: Resource nodes list.
Description: Gets the properties of a resource node.
    HTTP Method: GET/POST
    URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_node_prop&jrs.path=RESOURCENODE
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_node_prop&jrs.path=/SampleReports/SampleReports.cat
    Response: Resource node properties.
Description: Deletes the resource node from the resource tree.
    HTTP Method: GET/POST
    URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.delete_resource&jrs.path=RESOURCENODE
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.delete_resource&jrs.path=/SampleReports/Invoice Report.cls
Description: Gets the parameter page for specifying parameter values of a report.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_rpt_param_page&jrs.catalog=CATALOG&jrs.report=REPORT
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_rpt_param_page&jrs.catalog=/SampleReports/SampleReports.cat&jrs.report=/SampleReports/Invoice Report.cls
Description: Gets the Advanced Run page for choosing the result type of a report.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_rpt_desc_page&jrs.catalog=CATALOG&jrs.report=REPORT
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_rpt_desc_page&jrs.catalog=/SampleReports/SampleReports.cat&jrs.report=/SampleReports/Invoice Report.cls
Description: Creates a schedule task for a report.
    HTTP Method: GET/POST
    URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.submit_schedule&jrs.catalog=CATALOG_NAME&jrs.report=REPORT_NAME&jrs.task_class=TASK_CLASS_NAME&jrs.launch_type=TIME_TYPE&jrs.param$PARAMETER_NAME=VALUE&jrs.uid=USER_ID&jrs.to_version=BOOLEAN&jrs.to_version_rst=BOOLEAN
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.submit_schedule&jrs.catalog=%2fSampleReports%2fSampleReports.cat&jrs.task_class=jet.server.schedule.jrtasks.PublishRptTask&jrs.launch_type=0&jrs.param$P_StartDate=2006-01-01&jrs.param$p_EndDate=2007-12-31&jrs.uid=admin&jrs.to_version=true&jrs.to_version_rst=true&jrs.report=%2fSampleReports%2fCorporate Overview.cls
Description: Opens the Schedule page to create a new schedule for a report.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_new_schd_page&jrs.catalog=CATALOG_NAME&jrs.report=REPORT_NAME
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_new_schd_page&jrs.catalog=/SampleReports/SampleReports.cat&jrs.report=/SampleReports/Corporate Overview.cls
Description: Opens the Schedule page to edit an existing schedule task.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_edit_schd_page&jrs.task_id=TASK_ID
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_edit_schd_page&jrs.task_id=2003-12-11 11:09:16.455
Description: Gets the schedules list.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_schedules
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_schedules
Description: Deletes a schedule.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.del_schedule&jrs.task_id=TASK_ID
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.del_schedule&jrs.task_id=2003-12-11 11:09:16.455
Description: Enables a schedule.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.enable_schedule&jrs.task_id=TASK_ID
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.enable_schedule&jrs.task_id=2003-12-11 11:09:16.455
Description: Disables a schedule.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.disable_schedule&jrs.task_id=TASK_ID
        URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.disable_schedule&jrs.task_id=2003-12-11 11:09:16.455
Description: Gets the completed tasks list.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_completed
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_completed
Description: Gets the active tasks list.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_active
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_active
Description: Gets a list of reports running in background.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_ondemands
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_ondemands
      Response: Background run report list.
Description: Stops an active task.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.stop_task&jrs.task_id=TASK_ID
        URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.stop_task&jrs.task_id=2003-12-11 11:13:23.02
Description: Deletes a completed task.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.del_completed&jrs.id=RECORD_ID
        URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.del_completed&jrs.id=1071119897006-154848108
        You need to  invoke API to get RECORD_ID. A demo called APIDemoPublishRpt.java in <install_root>\help\samples\APIServer shows how to get completed task record including RECORD_ID.
Description: Deletes all completed tasks.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.del_all_completed
        URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.del_all_completed
Description: Gets the version table of a catalog.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_cat_vers&jrs.catalog=CATALOG
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_cat_vers&jrs.catalog=/SampleReports/SampleReports.cat
Description: Gets the version table of a report.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_rpt_vers&jrs.report=REPORT
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_rpt_vers&jrs.report=/SampleReports/Invoice Report.cls
Description: Gets the result version table of a report.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_rst_vers&jrs.catalog=CATALOG&jrs.report=REPORT_SET
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_rst_vers&jrs.catalog=/SampleReports/SampleReports.cat&jrs.report=/SampleReports/Invoice Report.cls
Description: Gets the result version table of a result document. The result document can be generated by advanced running or scheduling a report.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_rst_doc_vers&jrs.result=RESULT
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_rst_doc_vers&jrs.result=/SampleReports/Invoice Report
Description: Gets the parameter file of a report's result version.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver/REPORT?jrs.cmd=jrs.get_ver_param&jrs.version_id=VERSION_ID
      URL Example: http://localhost:8888/jrserver/SampleReports/SampleReports.cat/Invoice Report.cls?jrs.cmd=jrs.get_ver_param&jrs.version_id=103
Description: Gets a result version of the report from the version manager.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_ver_rst_page&jrs.file=FILE_NAME
      URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_ver_rst_page&jrs.file=1%5cJReport_System_User327406359%5cInvoice Report.rst
    Response: The result file from the version manager.
Description: Gets an HTML page for viewing a result version of a report with the ViewerApplet.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver/REPORT?jrs.cmd=jrs.get_ver_rst&jrs.file=FILE_NAME
      URL Example: http://localhost:8888/jrserver/SampleReports/SampleReports.cat/Invoice Report.cls?jrs.cmd=jrs.get_ver_rst&jrs.file=1%5cJReport_System_User327406359%5cInvoice Report.rst
      
    Response: HTML page for viewing the result file with the ViewerApplet.
Description: Deletes a version of a report.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver/REPORT?jrs.cmd=jrs.del_rpt_ver&jrs.version_id=VERSION_ID
        URL Example:  http://localhost:8888/jrserver/SampleReports/SampleReports.cat/Invoice Report.cls?jrs.cmd=jrs.del_rpt_ver&jrs.version_id=103
Description: Deletes a result version of a report.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver/REPORT?jrs.cmd=jrs.del_rst_ver&jrs.version_id=VERSION_ID
        URL Example:  http://localhost:8888/jrserver/SampleReports/SampleReports.cat/Invoice Report.cls?jrs.cmd=jrs.del_rst_ver&jrs.version_id=106
Description: Deletes a version of a result document.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.result=RESULT&jrs.cmd=jrs.del_rstdoc_ver&jrs.version_id=VERSION_ID
        URL Example:  http://localhost:8888/jrserver?jrs.result=/SampleReports/Invoice Report&jrs.cmd=jrs.del_rstdoc_ver&jrs.version_id=108
Description: Gets an HTML page in order to change the user preference settings with a web browser.
      HTTP Method: GET/POST
      URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_preference_page
    URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_preference_page
Description: Gets an HTML page in order to change the password with a web browser.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.get_change_password_page
        URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.get_change_password_page
Description: Changes the password for a user.
        HTTP Method: POST
        Form Action: http://HOST:PORT/jrserver?jrs.cmd=jrs.change_password
        Content Type: application/x-www-form-urlencoded
        Content: jrs.cmd=jrs.change_password&jrs.uid=admin&jrs.password=CURRENT_PASSWORD&jrs.new_password=NEW_PASSWORD&jrs.confirm_new_password=NEW_PASSWORD 
        Content Example: jrs.cmd=jrs.change_password&jrs.uid=admin&jrs.password=ad&jrs.new_password=1234&jrs.confirm_new_password=1234
Description: Logs out from the server.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.logout
        URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.logout
Description: Logs  onto the server from a login dialog with a web browser.
        HTTP Method: GET/POST
        URL Format: http://HOST:PORT/jrserver?jrs.cmd=jrs.login
        URL Example: http://localhost:8888/jrserver?jrs.cmd=jrs.login