MENU
    List Templates
    • 29 Mar 2024
    • 1 Minute to read
    • Contributors

    List Templates


    Article summary

    /profiles/{Profile ID}/templates/ returns a list of the template definitions (and their report definitions) that are associated with the specified profile.

    Method: GET

    URI: /profiles/{Profile ID}/templates/

    Note: Add any optional parameters to the end of the URI. If you change the order of URI or required parameters, or place optional parameters before them, the call will not work.

    Version number

    The version number you will use is dependant upon the version of Analytics you have installed. Analytics versions 9.5 and below, use v2_0. Analytics versions 9.5.1 and above will use v2_1.

    Example Request
    https://myDomain.com/{version}/ReportService/profiles/K729vc8Qqj5/templates/?format=xml&suppress_error_codes=true

    Example Response

    <list>
      <Template>
        <string name="ID">7cqana568rn</string>
        <string name="Name">Complete View</string>
        <string name="Description">Complete View</string>
        <decimal name="AccountID">1</decimal>
        <list name="Reports">
          <ReportDefinition>
            <decimal name="accountID">1</decimal>
              <string name="name">Initial Search Engines</string>
              <string name="ID">uK4gTGvcNj5</string>
              <string name="Category">%%SearchEngines%%</string>
          </ReportDefinition>
        </list>
      </Template>
      <Template>
        <string name="ID">4c5afa568</string>
        <string name="Name">My  View</string>
        <string name="Description">My View</string>
        <decimal name="AccountID">1</decimal>
        <list name="Reports">
          <ReportDefinition>
            <decimal name="accountID">1</decimal>
              <string name="name">Initial Search Engines</string>
              <string name="ID">uK4gTGvcNj5</string>
              <string name="Category">%%SearchEngines%%</string>
          </ReportDefinition>
        </list>
      </Template>
    </list>
    Plain text

    Parameters:

    Format

    format = return data format

    Data formatParameter and value
    JSONformat=json
    XMLformat=xml
    XML2 ("XPath-friendly" XML for dynamic applications)format=xml2

    For report data requests, all formats are supported. For "list" requests, only XML and JSON formats are supported.

    Suppress error codes

    Set the suppress_error_codes parameter to true if you do not want to be notified of error conditions for a request (the default is false).

    suppress_error_codes = {true|false}
    Example: Suppress errors for a request
    suppress_error_codes=true


    Was this article helpful?