POST DueFormInstances
Description
This API endpoint initiates the process of generating forms within the system. It serves as the trigger for creating various forms necessary for compliance or reporting purposes.
Endpoint
• Endpoint: <environment base url>/v1.0/api/Forms/DueFormInstances
• Method: POST
Request Body
{
"forms": [
{
"formId": "string",
"reportingPeriodFromDate": "string",
"reportingPeriodToDate": "string",
"reportingPeriodicity": "string",
"reportingPeriodNum": "string",
"reportingPhase": "string",
"reportingPhaseIndex": "string",
"locationId": "string",
"dataSelectionFromDate": "string",
"dataSelectionToDate": "string"
}
],
"externalReportingEntity": "string"
}`
Response Structure
A standard HTTP response with additional error details.
API Contract
Permitted values
reportingPhase
Code | Value |
---|---|
STAND | Declaration |
CORR | Correction |
reportingPeriodicity
Code | Frequency |
---|---|
B | Bi-weekly |
W | Weekly |
M | Monthly |
BM | Bi-Monthly |
Q | Quarterly |
HY | Half Yearly |
Y | Yearly |
Field Specifications
- formId: Max length 255.
- reportingPeriodFromDate, reportingPeriodToDate, dataSelectionFromDate, and dataSelectionToDate: Dates in the format yyyy-mm-dd.
- reportingPhaseIndex: Max length 2.
- reportingPeriodNum: Max length 2.
- locationId: Max length 1333. (Optional)
- externalReportingEntity: Max length 255.
Additional Notes
- If locationId is not provided, forms will be generated for all configured locations if location-based reporting is enabled for the form.
- Data selection dates are optional. If not provided, data will be selected based on the reporting period; otherwise, data will be selected based on the provided dates.
- If reportingPhase is passed as CORR, it will be treated as an Amendment request.
- In case of connectivity issues, retries can be made with the same job-id.
Sample Response
{
}
Sample request [CURL]
curl --location 'https://exampleapi.example.net/v1.0/api/Forms/DueFormInstances' \
--header 'x-request-id: example-request-id-1234-5678-90ab-cdef12345678' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer exampleToken1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz' \
--header 'Cookie: incap_ses_1607_1234567=exampleCookieValue1; incap_ses_76_1234567=exampleCookieValue2; incap_ses_8216_1234567=exampleCookieValue3; nlbi_1234567=exampleCookieValue4; visid_incap_1234567=exampleCookieValue5' \
--data '{
"forms": [
{
"formId": "EX_Form01",
"reportingPeriodFromDate": "2023-03-01",
"reportingPeriodToDate": "2023-03-31",
"reportingPeriodicity": "",
"reportingPeriodNum": "",
"reportingPhase": "STAND",
"locationId": ""
}
],
"externalReportingEntity": "EX123456"
}'