The Post Report endpoint is used to start the creation of a dataset for the ad hoc report specified in this call.
Overview
The URL for the Post Report request uses the following base URL:
https://www.dayforcehcm.com/api/CompanyName/V1/Reports/{reportId}
The Post Report 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 and 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
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 using via Dayforce Developer's Network (DDN) is not supported. This authorization may also be provided with basic user authentication.
Request Body
The request body should be used to include any filters and parameters related to a specific report. All required filters and parameters must be added with no default values. Required fields include Name
, Value
, and Sequence
for each filter, and Name
and Value
for each parameter. All parameter names should start with the "@
" symbol. You may change the default value of the filters tagged as Editable
.
Note: The ListValueID
should be used for filters and parameters with no default value. The corresponding ListValueID
for each report can be found in the Get Report Metadata calling in your Web Services Explorer.
{ "Filters": [ { "Name": "Recent Hire Date", "Value": "@EffectiveEnd", "Sequence": 1 }, { "Name": "Recent Hire Date", "Value": "@EffectiveStart", "Sequence": 2 }, { "Name": "Location", "Sequence": 4, "ListValueId": 1000 }, { "Name": "@Effective", "Description": "@Effective", "DataType": "Date", "Operator": "between", "IsRequired": true, "Value": "2023-01-13T00:00:00-05:00", "Editable": true } } }
Response
The response is in JSON format as illustrated in the example below:
{ "Data": { "DatasetId": "46ca93ab-b43c-42f9-bded-c91621ad2c6f", "Status": "Requested" } ] }