Skip to main content

Templates

Manage report templates, visual templates, and input configuration templates.

Overview

Templates provide reusable configurations for reports:

  • Report Templates - Complete report layouts and structure
  • Visual Templates - Chart and visualization configurations
  • Input Templates - User input parameter definitions
  • Input Filter Templates - Filter UI configurations

GET /api/report-templates

Get all available report templates.

Authentication: Required

Response:

The report-builder templates available for creating new reports.

List the report-template catalogGET /api/report-templates
The report-builder templates available for creating new reports.
Response · 200
{
"_links": {
"self": {
"href": "https://informer.example.com/api/report-templates"
}
},
"items": [
{
"detective": "00000000-0000-4000-8000-000000000001",
"id": "00000000-0000-4000-8000-000000000001:0",
"value": {
"group": "Ad hoc Query",
"name": "Native SQL",
"priority": 200,
"iconSvg": "/images/query/native-sql-query.svg",
"language": "sql",
"editOnCreate": true,
"rel": "inf:queries",
"searchDriver": "adhoc",
"editorComponent": {
"newReportDialog": {
"name": "Ad hoc Native SQL Query",
"description": "Write your own Query through a SQL statement",
"iconSvg": "/images/query/native-sql-query.svg",
"color": "deepPurple",
"component": {
"newNativeSqlEditor": {
"datasources": [
{
"defaultLinkType": "sql",
"aiSystemMessage": "This is a PostgresSQL database. Identifiers are case-sensitive by default. \n Always surround all column names, table names, and schema names in double-quotes (\"). \n For example:\n SELECT \"OrderID\", \"ShipCountry\" FROM \"public\".\"orders\" WHERE \"ShipCity\" = 'Raleigh';\n ---",
"family": "sql",
"languages": [
"informer",
"sql",
"distinctValue",
"… 2 more items (5 total) — omitted from docs"
],
"naturalId": "admin:northwind",
"image": "/opt/informer/packages/informer-server/modules/sql/images/postgres.svg",
"compatibility": [],
"permissions": {
"assignTags": false,
"edit": false,
"delete": false,
"share": false,
"write": false,
"changeOwner": false,
"ping": false,
"scan": false,
"downloadSchema": false,
"importData": false,
"importSchema": false,
"rename": false,
"editConnection": false,
"createLink": false,
"setWrite": false,
"createSuite": false,
"createFieldExpression": false,
"createMapping": false,
"bundle": false,
"query": false
},
"id": "00000000-0000-4000-8000-000000000002",
"tenant": "acme",
"ownerId": "admin",
"slug": "northwind",
"name": "Northwind",
"description": null,
"embedded": false,
"type": "postgres",
"connection": {
"host": "localhost",
"pool": {
"max": 5,
"min": 0,
"idle": 10000,
"acquire": 10000
},
"port": 5432,
"user": "northwinduser",
"database": "northwind",
"password": "encrypted:iv:0000000000000000",
"idleTimeoutMillis": 7
},
"scannedAt": "2026-01-15T16:20:00.000Z",
"schemaUpdatedAt": "2026-01-15T16:20:00.000Z",
"rescanRequired": false,
"shared": false,
"schemas": [
"public"
],
"source": null,
"sourceId": null,
"settings": {
"multiSchema": false,
"useFakeData": false,
"remoteQueryBatchSize": {
"multiKey": 500,
"singleKey": 500
},
"usePreparedStatements": false
},
"data": null,
"appId": null,
"createdAt": "2026-01-15T16:20:00.000Z",
"updatedAt": "2026-01-15T16:20:00.000Z",
"folderId": null,
"fileId": null
}
]
}
}
}
},
"report": {
"language": "sql"
}
}
},
{
"detective": "00000000-0000-4000-8000-000000000003",
"id": "00000000-0000-4000-8000-000000000003:0",
"value": {
"group": "Pixel Perfect",
"name": "Template",
"priority": 100,
"iconSvg": "/assets/reports/images/template.svg",
"editOnCreate": true,
"draftPrepared": true,
"rel": "inf:templates",
"searchDriver": "template",
"editorComponent": {
"newReportDialog": {
"name": "New Template",
"description": "Create a new templated rich document that can bind content to data from Datasets, Ad hoc Queries, and Files",
"iconSvg": "/assets/reports/images/template.svg",
"component": "newTemplateReport"
}
},
"report": {
"type": "nunjucks",
"handler": "pdf",
"handlerOptions": {
"letterheadOverrides": {},
"manualOptions": {
"fontName": "Roboto",
"fontSize": 11,
"pageSize": "letter",
"orientation": "Portrait",
"marginTop": 10,
"marginBottom": 10,
"marginLeft": 10,
"marginRight": 10,
"footer": {},
"header": {}
}
},
"initialFiles": [
{
"primary": true,
"role": "TEMPLATE",
"filename": "template.njk",
"contentType": "text/html",
"payload": "<!DOCTYPE html>\n<html lang=\"en\">\n\n<head>\n <meta charset=\"UTF-8\">\n <link rel=\"stylesheet\" href=\"{{url('style.css')}}\">\n</head>\n\n<body>\n <div>Hello, world!</div>\n</body>\n\n</html>"
},
{
"role": "ASSET",
"filename": "style.css",
"contentType": "text/css"
},
{
"role": "TEMPLATE",
"filename": "helpers.js",
"contentType": "application/javascript"
}
]
}
}
},
{
"detective": "00000000-0000-4000-8000-000000000004",
"id": "00000000-0000-4000-8000-000000000004:0",
"value": {
"group": "Ad hoc Query",
"name": "Query Designer",
"priority": 100,
"iconSvg": "/assets/query-languages/images/query-designer.svg",
"language": "informer",
"editOnCreate": true,
"rel": "inf:queries",
"searchDriver": "adhoc",
"editorComponent": {
"newReportDialog": {
"name": "Ad hoc Query",
"description": "Design a Query by choosing rows and columns from a Datasource",
"iconSvg": "/assets/query-languages/images/query-designer.svg",
"color": "blue",
"component": "newQueryDesigner"
}
},
"report": {
"language": "informer"
}
}
},
"… 3 more items (6 total) — omitted from docs"
],
"start": 0,
"count": 6,
"total": 6
}
Captured from the API examples test suite; ids and timestamps are normalized.

GET /api/reports/template

Get the default report template.

Authentication: Required

Response:

Returns the default template object.


GET /api/reports/{id}/templates

Get all templates associated with a specific report.

Authentication: Required

Path Parameters:

ParameterTypeDescription
idstringReport ID

Response:

The ReportTemplate bindings (output templates) attached to this report.

List a report’s attached templatesGET /api/reports/admin:sales-overview/templates
The ReportTemplate bindings (output templates) attached to this report.
Response · 200
{
"_links": {
"self": {
"href": "https://informer.example.com/api/reports/admin%3Asales-overview/templates"
}
},
"items": [],
"start": 0,
"count": 0,
"total": 0
}
Captured from the API examples test suite; ids and timestamps are normalized.

POST /api/reports/{id}/templates

Associate a template with a report.

Authentication: Required

Path Parameters:

ParameterTypeDescription
idstringReport ID

Request Body:

{
"templateId": "template-1"
}

Response:

{
"id": "uuid",
"reportId": "team:sales-dashboard",
"templateId": "template-1"
}

Status Code: 201 Created


GET /api/reports/{id}/visual-templates

Get available visual templates for a report.

Authentication: Required

Path Parameters:

ParameterTypeDescription
idstringReport ID

Response:

Returns an array of visual template definitions (charts, tables, etc.) compatible with the report.

[
{
"id": "bar-chart",
"name": "Bar Chart",
"type": "chart",
"component": {}
},
{
"id": "line-chart",
"name": "Line Chart",
"type": "chart",
"component": {}
}
]

Use Case:

Get available visualization types when building or editing a report.


GET /api/reports/{id}/input-templates

Get available input parameter templates for a report.

Authentication: Required

Path Parameters:

ParameterTypeDescription
idstringReport ID

Response:

Returns an array of input parameter template definitions.

[
{
"id": "date-range",
"name": "Date Range",
"type": "dateRange",
"config": {}
},
{
"id": "region-select",
"name": "Region Selector",
"type": "select",
"config": {}
}
]

Use Case:

Get available input types when defining report parameters.


GET /api/reports/{id}/input-filter-templates

Get available input filter templates for a report.

Authentication: Required

Path Parameters:

ParameterTypeDescription
idstringReport ID

Response:

Returns an array of filter template definitions.

List input filter templates for a reportGET /api/reports/admin:sales-overview/input-filter-templates
Response · 200
{
"_links": {
"self": {
"href": "https://informer.example.com/api/reports/admin%3Asales-overview/input-filter-templates"
}
},
"items": [],
"start": 0,
"count": 0,
"total": 0
}
Captured from the API examples test suite; ids and timestamps are normalized.

Use Case:

Get available filter UI components when building report inputs.