Get Form Compliance

Introduction

This API provides for one or more forms the current form design with additional emphasis on values allowed for user entry, the compliance tolerances and related settings per Resource on each field within a form.

Getting Started

All API requests require an authorization token – reference our Authentication page for more information

API Structure

POST api/Integration/GetFormCompliance

Required Request Parameters

NameLocationOptionsDescription
Authorization tokenHeaderSee Login Authentication API documentation
TakeBodyRecommended default 100Paging the data
SkipBodyrecommended default 0Paging the data
Form NamesBodyOptional: include more Form Names by separating form names with commas

Request JSON

{
    "Data": {
        "Take": 100,
        "Skip": "",
        "FormNames": [
            "Metal Detector Check"
        ]
    }
}

Response Parameters

NameDescription
Form TypeCheck, Audit or Questionnaire see Form Integration API documentation
Form Details, FieldsList of all fields and their related criteria within the Form
Field Type, Data TypeDenotes the type of Field

Type : Description
• FreeText : Open ended text entry
• Date : Month Day Year date field
• Paragraph : Free Text field with larger text limit threshold
• SelectOne : Drop down that allows users to pick only one value
• SelectMultiple : Drop down that allows users to pick one or more values
• Numeric : Text entry field restricted to numerical integers
• Time : Hour Minute time field
• Identifier : Free text or select one field that allows for values to be filtered within Analytics
• FieldGroup : Groups fields, can be triggered by a dependency
ElementTypeInternal field for SafetyChain purposes, will always be set to Field
ConfigurationList of the Compliance and field settings per resource and if default across all resources is in use
OptionsOnly shown for types SelectOne and SelectMultiple – options within the dropdown presented to the user
IsVisibleDenotes if the field is visible to the resource
IsDefaultDenotes if the field is using the default compliance or has acceptance criteria unique to the resource
Min, Max, Target, UOMNumerical range values allowed for only Numeric type questions
ComplianceValueThe tolerance of values entered by the user, or chosen from the drop down, to result in a compliant answer
SubjectDenotes if the GUID and Resource Name of all resources associated with the form. Default is not a Resource but used in
IsValidSet to false, used for internal SafetyChain properties.
IsDefaultDenotes if the compliance settings are set across all resources via the Default, or configured per Resource
ShortNameUnique text based GUID for individual fields
Field IDGUID associated with the individual field
VersionTroubleshooting aid, do not increment this value manually!
Field NameName of form

Response JSON

{
    "Data": {
        "Forms": [{
                "Type": "Check",
                "FormData": {
                    "FormDetails": {
                        "Fields": [{
                                "Type": "Numeric",
                                "ElementType": "Field",
                                "Configuration": [{
                                        "Compliance": {
                                            "DataType": "Numeric",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": null
                                        },
                                        "IsVisible": true,
                                        "Subject": {
                                            "Id": "2d212701-73d8-4ba9-a725-722abef5da02",
                                            "Name": "Default"
                                        },
                                        "IsValid": false,
                                        "IsDefault": false
                                    }, {
                                        "Compliance": {
                                            "DataType": "Numeric",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": null
                                        },
                                        "IsVisible": true,
                                        "Subject": {
                                            "Id": "72d2b865-1600-485c-b9f1-28b1d8e2dfc7",
                                            "Name": "Equipment > Equipment > Quality Control > Metal Detector"
                                        },
                                        "IsValid": false,
                                        "IsDefault": false
                                    }
                                ],
                                "ShortName": "Number of bags rejected",
                                "Id": "241cb5ea-b132-41ad-a837-21c37c1cb357",
                                "Name": "Number of bags rejected"
                            }, {
                                "Type": "SelectOne",
                                "Options": [{
                                        "Id": "9dd3c4b6-a475-41ac-ac5d-9b462da804dc",
                                        "Name": "Yes"
                                    }, {
                                        "Id": "fd8a5a76-8f3d-48dd-9a58-281668c03df9",
                                        "Name": "No"
                                    }
                                ],
                                "ElementType": "Field",
                                "Configuration": [{
                                        "Compliance": {
                                            "DataType": "SelectOne",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": "Yes"
                                        },
                                        "IsVisible": true,
                                        "Subject": {
                                            "Id": "72d2b865-1600-485c-b9f1-28b1d8e2dfc7",
                                            "Name": "Equipment > Equipment > Quality Control > Metal Detector"
                                        },
                                        "IsValid": false,
                                        "IsDefault": true
                                    }, {
                                        "Compliance": {
                                            "DataType": "SelectOne",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": "Yes"
                                        },
                                        "IsVisible": false,
                                        "Subject": {
                                            "Id": "2d212701-73d8-4ba9-a725-722abef5da02",
                                            "Name": "Default"
                                        },
                                        "IsValid": false,
                                        "IsDefault": false
                                    }
                                ],
                                "ShortName": "Was shift leader notified",
                                "Id": "a501260d-4dea-4be8-b125-900bcf563f4b",
                                "Name": "Was shift leader notified?"
                            }, {
                                "Type": "SelectOne",
                                "Options": [{
                                        "Id": "be4b8e70-b0d5-42e3-85c3-2f382e85cb99",
                                        "Name": "Yes"
                                    }, {
                                        "Id": "6190f476-5f12-4a6f-b1b1-0221440829f2",
                                        "Name": "No"
                                    }
                                ],
                                "ElementType": "Field",
                                "Configuration": [{
                                        "Compliance": {
                                            "DataType": "SelectOne",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": null
                                        },
                                        "IsVisible": true,
                                        "Subject": {
                                            "Id": "2d212701-73d8-4ba9-a725-722abef5da02",
                                            "Name": "Default"
                                        },
                                        "IsValid": false,
                                        "IsDefault": false
                                    }, {
                                        "Compliance": {
                                            "DataType": "SelectOne",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": null
                                        },
                                        "IsVisible": true,
                                        "Subject": {
                                            "Id": "72d2b865-1600-485c-b9f1-28b1d8e2dfc7",
                                            "Name": "Equipment > Equipment > Quality Control > Metal Detector"
                                        },
                                        "IsValid": false,
                                        "IsDefault": false
                                    }
                                ],
                                "ShortName": "Was the product retrieved",
                                "Id": "4056e7b5-8350-491b-a8d7-c4041b7eece3",
                                "Name": "Was the product retrieved by QA?"
                            }, {
                                "Type": "Paragraph",
                                "ElementType": "Field",
                                "Configuration": [{
                                        "Compliance": {
                                            "DataType": "Paragraph",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": null
                                        },
                                        "IsVisible": true,
                                        "Subject": {
                                            "Id": "2d212701-73d8-4ba9-a725-722abef5da02",
                                            "Name": "Default"
                                        },
                                        "IsValid": false,
                                        "IsDefault": false
                                    }, {
                                        "Compliance": {
                                            "DataType": "Paragraph",
                                            "Min": null,
                                            "Max": null,
                                            "Target": null,
                                            "UOM": null,
                                            "ComplianceValue": null
                                        },
                                        "IsVisible": true,
                                        "Subject": {
                                            "Id": "72d2b865-1600-485c-b9f1-28b1d8e2dfc7",
                                            "Name": "Equipment > Equipment > Quality Control > Metal Detector"
                                        },
                                        "IsValid": false,
                                        "IsDefault": false
                                    }
                                ],
                                "ShortName": "Comments:",
                                "Id": "c55fc8eb-c700-4f83-b803-4d41c1e7703a",
                                "Name": "Comments:"
                            }
                        ]
                    }
                },
                "Version": "2.0",
                "Resources": [{
                        "Id": "2d212701-73d8-4ba9-a725-722abef5da02",
                        "Name": "Default"
                    }, {
                        "Id": "72d2b865-1600-485c-b9f1-28b1d8e2dfc7",
                        "Name": "Equipment > Equipment > Quality Control > Metal Detector"
                    }
                ],
                "isPartial": false,
                "ActionType": null,
                "Id": "64929aee-ab7a-4273-9e9f-f3c63dae743e",
                "Name": "Metal Detector Check"
            }
        ]
    },
    "Status": true,
    "Errors": null,
    "RefreshToken": false
}