Skip to content

Report Template


Endpoints

GET       /report_templates
GET       /report_templates/:id
DELETE    /report_templates/:id

A report template is a set of reporting widgets that are able to calculate, visualize and aggregate analytics based on a portfolio and/or datastores.

The report template object

What a report object looks like?

{
  "status": "OK",
  "updated": 1624633635,
  "name": "My First Report Template",
  "tags": ["first", "new", "report_template"],
  "created": 1624633635,
  "workspace": "main",
  "id": "rtpl_UHAo64xdlah3iR9lZgB6LFwAb",
  "categories": [],
  "description": "Design a custom report using Everysk's library of widgets and analytics. #blank #new #report"
}
Property Description
id string Unique identifier (UID) for the report template.
created timestamp Time at which the object was created. Measured in seconds since the Unix epoch.
updated timestamp Time at which the object was updated. Measured in seconds since the Unix epoch.
name string The report template's name.
description string An arbitrary string attached to the report template. Often useful for finding detailed information about the report template or for filtering a search based on the present hashtags.
tags array Sequence of hashtags used to find the related report template. The more hashtags that are used, the more elements that are filtered out from the search. Labels, dates and any other hashtag can be used.
authorization string Indicates whether the report template is public or not.
categories array The report template category.
workspace string The workspace where the report template was generated.

List all Report Templates

Returns a list of report templates you’ve previously generated. The report templates are returned in sorted order, with the most recent report template appearing first.

To list all report templates, run the following:

curl https://api.everysk.com/v2/report_templates?query=#first&workspace=main \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <ACCESS_TOKEN>" \
  -G

The above call returns the following JSON object:

{
  "report_templates": [
    {
      "status": "OK",
      "updated": 1632329105,
      "name": "First Report Template",
      "tags": ["first", "new", "report_template"],
      "created": 1630348524,
      "workspace": "main",
      "id": "rtpl_oobGe082N8U4PPhLrU60xNOLT",
      "categories": [],
      "description": "Design a custom report using Everysk's library of widgets and analytics. #blank #new #report"
    },
    {
      "status": "OK",
      "updated": 1627663323,
      "name": "Second Report Template",
      "tags": ["blank", "new", "report"],
      "created": 1627593196,
      "workspace": "main",
      "id": "rtpl_oZbdHf786RRZIGN3WJQSY2M88",
      "categories": [],
      "description": "Design a custom report using Everysk's library of widgets and analytics. #blank #new #report"
    }
  ],
  "next_page_token": null
}

HTTP Request

GET /report_templates

HTTP Parameters

Parameter Description
query string optional, default is null Request a list of report templates filtering it by name or tag. When using a tag to perform a query, each term must include a hashtag prefix. (e.g: query="#april #sample")
page_size int optional, default is 10 Set the number of objects that will be listed per page.
page_token int optional, default is null The token defines which page will be returned to the user. For further information, please check out our pagination guide.
workspace string optional, default is main Determines on which workspace the request will be made.

Retrieve a report template

Retrieves the details of an existing report template by supplying the report template's id.

To retrieve a report template, run the following:

curl https://api.everysk.com/v2/report_templates/rtpl_UHAo64xdlah3iR9lZgB6LFwAb?workspace=main \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <ACCESS_TOKEN>" \
  -G

The above call returns the following JSON object:

{
  "report_template": {
    "status": "OK",
    "updated": 1624633635,
    "layout": [
      ...
    ],
    "description": "Design a custom report using Everysk's library of widgets and analytics. #blank #new #report",
    "created": 1624633635,
    "tags": [
      "first",
      "new",
      "report_template"
    ],
    "workspace": "main",
    "global_parameters": {
      "advanced_settings": {
        "confidence": {
          "variant": "select",
          "select": {
            "value": "95%",
            "label": "95%"
          }
        },
        "correlation_half_life": {
          "variant": "select",
          "select": {
            "value": 6,
            "label": "6-months"
          }
        }
        ...
      }
    },
    "id": "rtpl_UHAo64xdlah3iR9lZgB6LFwAb",
    "categories": [],
    "name": "First Report Template"
  }
}

HTTP Request

GET /report_templates/:id

HTTP Parameters

Parameter Description
id string REQUIRED A unique identifier (UID) for a report template. A report template's id will always look like this: rtpl_UHAo64xdlah3iR9lZgB6LFwAb.
workspace string optional, default is main Determines on which workspace the request will be made.

Delete a report template

To delete a report template, run the following:

curl https://api.everysk.com/v2/report_templates/rtpl_UHAo64xdlah3iR9lZgB6LFwAb?workspace=main \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <ACCESS_TOKEN>" \
  -X DELETE

The above call returns the following JSON object:

{
  "report_template": {
    "deleted": true,
    "id": "rtpl_UHAo64xdlah3iR9lZgB6LFwAb",
    "name": "First Report Template"
  }
}

Permanently deletes a report template. It cannot be undone. Returns an object with the report template's id and an attribute specifying whether the report was successfully deleted or not.

HTTP Request

DELETE /report_templates/:id

HTTP Parameters

Parameter Description
id string REQUIRED A unique identifier (UID) for a report.
workspace string optional, default is main Determines on which workspace the request will be made.