Get Report Templates Info (Server Tools)
Summary
Returns the content of report files and templates in JSON format. Report files (.rptx) and report templates (.rptt) are used to store report definitions.
Usage
This tool is intended to be published as a geoprocessing task in a printing service.
The output of this tool is a string formatted as JSON. The string is a list of available report templates and report files with the following information:
Report section information
Report name
Report data source
Related report section information
Relationship ID
Related report data source
Grouping
Field values
Field names
Statistics
A sample output JSON:
[{ "reportTemplate": "Attribute List Group Letter Landscape", // name of the template "reportOptions": { "Report Section": { "name": "My Report", // name of the report section "sourceId": "my_source", // report section data source "groupSections": { // field(s) used for grouping "Group Header: [group-field-value]": "Subdivision" }, "fieldElements": { // field(s) used for dynamic field values "Field 1": "APN10", "Field 2": "Address", }, "fieldLabelElements": { "Field Label 1": "Parcel", "Field Label 2": "Street Address" }, "statisticElements": { // field(s) used for statistics "Count Statistic Field 1": "APN10", } } } }, { "reportTemplate": "Custom_AttrList_RelatedReport_Port", "reportOptions": { "Report Section": { "name": "States Report", "sourceId": "us-states", "fieldElements": { "Field 1": "Name", "Field 2": "Population", "Field 3": "Region" }, "fieldLabelElements": { "Field Label 1": "State Name", "Field Label 2": "Current Population", "Field Label 3": "Region" }, "statisticElements": { "Count Statistic Field 1": "Name" } }, "Related Report Section": { "relatedId": "R1L1statesL0cities", //related report Id "sourceId": "us-cities", //related report data source "fieldElements": { "Related Field 1": "SqMi_Area", "Related Field 2": "Population" }, "fieldLabelElements": { "Related Field Label 1": "Area", "Related Field Label 2": "Population" } } } }]Use the same folder location of the associated Export Web Map tool.
For more information, see Printing in web applications in the ArcGIS Enterprise help.
Parameters
| Label | Explanation | Data type |
|---|---|---|
|
Report Templates Folder (Optional) |
The full path to the folder where the report files ( |
Folder |
|
Report Item ID (Optional) |
The portal ID (in JSON format) of the report item that will be used for the templates. Use the format |
String |
Derived output
| Label | Explanation | Data type |
|---|---|---|
|
JSON String |
A JSON formatted string. The string is a list of available report templates ( |
String |
Environments
This tool does not use any geoprocessing environments.
Licensing information
- Basic: Yes
- Standard: Yes
- Advanced: Yes