RESTful Get Report Metadata

Dayforce Data and Analytics Guide

Version
R2023.1.1
RESTful Get Report Metadata
The following function retrieves a report's metadata. You must have access to the report. The results can be used by the Post Report request to filter large datasets.

Overview

The Get Report Metadata request allows the consuming application to retrieve the metadata (fields, filters, etc.) of a report. Required parameters for the call include reportId, clientNamespace, and BearerToken, though the authorization provided by the BearerToken can also be provided through basic user authentication.

The URL for the Get Report Metadata request uses the following base URL:

https://www.dayforcehcm.com/api/ClientName/V1/Analytics/Reports/ReportId/Metadata

The Get Report Metadata endpoint follows ISO 8601 for date and time standards. The following standardized format will be used for date and time fields:

yyyy-mm-ddThh:mm:ss[+|-]hh:mm (server local date time with time offset to UTC time).

The following examples show how the format is used for different date and time data types:

  • Date Time: "Value": "2022-02-08T00:45:00-05:00"
  • Date: "2022-02-08T00:00:00-05:00" (include the time with 00 for hour, minute and second)
  • Time: "2022-02-08T14:15:30-05:00" (you can use the current date to call the API, or a valid date)

Parameters

Note: An asterisk (*) next to a parameter name denotes a required parameter.

reportId* (integer)

  • Uniquely identifies a report.

clientNamespace* (string)

  • Uniquely identifies the client's Dayforce instance. This is needed to log in.

BearerToken* (string)

  • Authorization Token is mandatory for this API. Testing this API in the Dayforce Developer's Network (DDN) is not supported. This authorization may also be provided with basic user authentication.

Response

The response is in JSON format as illustrated in the example below:

{
  "Data": [
    {
      "Name": "string",
      "Description": "string",
      "XRefCode": "string",
      "ReportId": 0,
      "MaxRows": 0,
      "OnlyIncludeUniqueRecords": true,
      "Columns": [
        {
          "Name": "string",
          "Description": "string",
          "DataType": "string"
        }
      ],
      "Filters": [
        {
          "Name": "string",
          "Description": "string",
          "DataType": "string",
          "Operator": "string",
          "IsRequired": true,
          "Value": "string",
          "Editable": true,
          "Sequence": 0,
          "AvailableValues": [
            {
              "ListValueId": 0,
              "Name": "string"
            }
          ]
        }
      ]
    }
  ],
  "ProcessResults": [
    {
      "Code": "string",
      "Context": "string",
      "Level": "string",
      "Message": "string"
    }
  ]
}