Get a data form

get

/km/api/v1/dataForms/{id}

This method returns the DataForm object having the specified ID parameter.

Example URIs

The example URIs for this method are as follows:

  • http://<IM_REST_API_HOST>/km/api/latest/dataForms/{id}

    The request returns the DataForm object having specified ID parameter in FULL mode.

  • http://<IM_REST_API_HOST>/km/api/dataForms/{id}?mode=KEY

    The request returns the DataForm object having specified ID parameter in the KEY mode.

Response Errors

  • OKDOM-GEN0001

    The error occurs when an invalid id has been given.

Request

Path Parameters
  • The unique identifier of the object to be retrieved.
Back to Top

Response

Supported Media Types

200 Response

OK.
Body ()
Root Schema : DataForm
Type: object
Title: DataForm
Show Source
Nested Schema : questions
Type: array
To Many Relationship to Question
Show Source
Nested Schema : UserKey
Type: object
Title: UserKey
Show Source
Nested Schema : views
Type: array
To Many Relationship to View
Show Source
Nested Schema : DataFormQuestion
Type: object
Title: DataFormQuestion
Show Source
Nested Schema : answers
Type: array
To Many Relationship to Answer
Show Source
Nested Schema : DataFormKey
Type: object
Title: DataFormKey
Show Source
Nested Schema : DataFormAnswer
Type: object
Title: DataFormAnswer
Show Source
Nested Schema : DataFormQuestionKey
Type: object
Title: DataFormQuestionKey
Show Source
Nested Schema : ViewKey
Type: object
Title: ViewKey
Show Source
Back to Top

Examples

The following example shows how to find the DataForm object having the specified ID parameter:

curl -X "GET" "http://IM_REST_API_HOST/km/api/latest/dataForms/{id}"

Example of Request Header

The following shows an example of the request header.

curl -X GET "https://<IM_REST_API_HOST>/km/api/latest/dataForms/{id}" -u "<username:password>" -H "Accept: application/json" -H "Content-Type: application/json"

Example of Response Body

The following shows an example of the response body in JSON format.

{
    "recordId": "45C98B085B044881821DE07F68DC14CF",
    "referenceKey": "YES_OR_NO_RATING",
    "links": [
        {
            "rel": "canonical",
            "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms/45C98B085B044881821DE07F68DC14CF",
            "mediaType": "application/json, application/xml",
            "method": "GET"
        },
        {
            "rel": "collection",
            "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms",
            "mediaType": "application/json, application/xml",
            "method": "GET",
            "profile": "https://<IM_REST_API_HOST>/km/api/latest/metadata-catalog/dataForms"
        }
    ],
    "dateAdded": "1970-01-01T23:11:11+0000",
    "dateModified": "1970-01-01T23:11:11+0000",
    "emailContent": false,
    "name": "Like/Dislike Rating",
    "displayEndDate": "4712-12-31T00:00:00+0000",
    "displayStartDate": "2000-01-01T00:00:00+0000",
    "ratingType": 2,
    "questions": [
        {
            "recordId": "94AEF5ABE53A4E609EFD0A208E9007C3",
            "referenceKey": "YES_OR_NO_RATING_Q1",
            "links": [
                {
                    "rel": "canonical",
                    "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms/45C98B085B044881821DE07F68DC14CF/questions/94AEF5ABE53A4E609EFD0A208E9007C3",
                    "mediaType": "application/json, application/xml",
                    "method": "GET"
                }
            ],
            "dateAdded": "1970-01-01T23:11:11+0000",
            "dateModified": "1970-01-01T23:11:11+0000",
            "isMasterIdentifier": true,
            "required": true,
            "sortOrder": 1,
            "specialTypeIndicator": -1,
            "name": "Does this document help you?",
            "answers": [
                {
                    "recordId": "874CF739B99F4D358050B6C5CCC819F6",
                    "referenceKey": "YES_OR_NO_RATING_A1",
                    "links": [
                        {
                            "rel": "canonical",
                            "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms/45C98B085B044881821DE07F68DC14CF/questions/94AEF5ABE53A4E609EFD0A208E9007C3/answers/874CF739B99F4D358050B6C5CCC819F6",
                            "mediaType": "application/json, application/xml",
                            "method": "GET"
                        }
                    ],
                    "dateAdded": "1970-01-01T23:11:11+0000",
                    "dateModified": "1970-01-01T23:11:11+0000",
                    "defaultAnswer": false,
                    "numberValue": 1,
                    "sortOrder": 1,
                    "name": "Dislike",
                    "dataFormQuestion": {
                        "recordId": "94AEF5ABE53A4E609EFD0A208E9007C3",
                        "referenceKey": "YES_OR_NO_RATING_Q1",
                        "links": [
                            {
                                "rel": "canonical",
                                "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms/45C98B085B044881821DE07F68DC14CF/questions/94AEF5ABE53A4E609EFD0A208E9007C3",
                                "mediaType": "application/json, application/xml",
                                "method": "GET"
                            }
                        ]
                    }
                },
                {
                    "recordId": "B73836830DC0401FA931120E4634408A",
                    "referenceKey": "YES_OR_NO_RATING_A2",
                    "links": [
                        {
                            "rel": "canonical",
                            "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms/45C98B085B044881821DE07F68DC14CF/questions/94AEF5ABE53A4E609EFD0A208E9007C3/answers/B73836830DC0401FA931120E4634408A",
                            "mediaType": "application/json, application/xml",
                            "method": "GET"
                        }
                    ],
                    "dateAdded": "1970-01-01T23:11:11+0000",
                    "dateModified": "1970-01-01T23:11:11+0000",
                    "defaultAnswer": false,
                    "numberValue": 2,
                    "sortOrder": 2,
                    "name": "Like",
                    "dataFormQuestion": {
                        "recordId": "94AEF5ABE53A4E609EFD0A208E9007C3",
                        "referenceKey": "YES_OR_NO_RATING_Q1",
                        "links": [
                            {
                                "rel": "canonical",
                                "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms/45C98B085B044881821DE07F68DC14CF/questions/94AEF5ABE53A4E609EFD0A208E9007C3",
                                "mediaType": "application/json, application/xml",
                                "method": "GET"
                            }
                        ]
                    }
                }
            ],
            "dataForm": {
                "recordId": "45C98B085B044881821DE07F68DC14CF",
                "referenceKey": "YES_OR_NO_RATING",
                "links": [
                    {
                        "rel": "canonical",
                        "href": "https://<IM_REST_API_HOST>/km/api/latest/dataForms/45C98B085B044881821DE07F68DC14CF",
                        "mediaType": "application/json, application/xml",
                        "method": "GET"
                    }
                ]
            }
        }
    ],
    "user": {
        "recordId": -999998,
        "name": "BatchJob User",
        "externalType": "ACCOUNT",
        "links": [
            {
                "rel": "canonical",
                "href": "https://<IM_REST_API_HOST>/km/api/latest/users/-999998",
                "mediaType": "application/json, application/xml",
                "method": "GET"
            }
        ]
    },
    "views": []
}
Back to Top