Purpose: Get a list of form submissions.

Base URL: https://www.commcarehq.org/a/[domain]/api/v0.5/form/

Input parameters:

The forms can be filtered using the following parameters, which also control paging of the output records.

NameDescriptionExampleStatus
xmlns

Form XML namespace (optional)

You can find this for any given form by going to your form -> Advanced -> View (Source xml) and look for the address in the header of your xform. It is also in the raw xml of any submitted form.

xmlns=http://openrosa.org/formdesigner/dd3190c7dd7e9e7d469a9705709f2f6b4e27f1d8

Supported
received_on_startDate Time (optional)received_on_start=2012-01-01 (or with Time 2012-01-01T06:05:42)Supported
received_on_endDate Time (optional)received_on_end=2013-02-03 (or with Time 2013-11-25T06:05:42)Supported
limitThe maximum number of records to return. Default: 20. Maximum: 1000limit=100Supported
offsetThe number of records to offset in the results. Default: 0.offset=100Supported
appVersionThe exact version of the CommCare application used to submit the form (this will be large and involved; it is intended for programmatic use)appVersion=v2.6.1%20(3b8ee4-e3dc9f-unvers-2.1.0-Nokia%2FS40-native-input)%20build%207313%20App%20%237300%20b%3A2013-Jun-04%20r%3A2013-Jul-18Supported
include_archivedWhen set to 'true' archived forms will be included in the response.include_archived=trueSupported
app_idThe returned records will be limited to the application definedapp_id=02bf50ab803a89ea4963799362874f0cSupported

Sample usage:

https://www.commcarehq.org/a/[domain]/api/v0.5/form/

Sample output:

{
  "meta": {
    "limit": 20,
    "next": "/a/corpora/api/v0.5/form/?limit=20&offset=20",
    "offset": 0,
    "previous": null,
    "total_count": 6909
  },
  "objects": [
    {
      "app_id": "effb341b",
      "archived": false,
      "attachments": {
        "form.xml": {
          "content_type": "text/xml",
          "length": 1103
        }
      },
      "build_id": "e0a6125",
      "domain": "my-project",
      "form": {
        "#type": "data",
        "@name": "Case Update",
        "@uiVersion": "1",
        "@version": "18",
        "@xmlns": "http://openrosa.org/formdesigner/4281EB62-46E6-49AD-A08C",
        "case": {
          "@case_id": "b6996b7b-6b3f-476a-9006",
          "@date_modified": "2016-11-29T14:50:41.156000Z",
          "@user_id": "e7ad965c",
          "@xmlns": "http://commcarehq.org/case/transaction/v2",
          "update": {
            "data_node": "55",
            "dateval": "2012-09-26",
            "geodata": "5.0 5.0 5.0 5.0",
            "intval": "5",
            "multiselect": "b",
            "singleselect": "b",
            "text": "TEST"
          }
        },
        "data_node": "55",
        "geodata": "5.0 5.0 5.0 5.0",
        "meta": {
          "@xmlns": "http://openrosa.org/jr/xforms",
          "appVersion": "CommCare Android, version \"2.31.0\"(423345). App v18. CommCare Version 2.31. Build 423345, built on: 2016-11-02",
          "app_build_version": 18,
          "commcare_version": "2.31.0",
          "deviceID": "358001070684648",
          "geo_point": null,
          "instanceID": "f959449c-8776-42ac-b776-3f564fafc331",
          "timeEnd": "2016-11-29T14:50:41.156000Z",
          "timeStart": "2016-11-29T14:50:36.155000Z",
          "userID": "e7ad965c70802884a7a67add763939e8",
          "username": "testuser"
        },
        "old_data_node": "",
        "question1": "OK",
        "question11": "5",
        "question12": "2012-09-26",
        "question14": "OK",
        "question3": "b",
        "question7": "b",
        "text": "TEST"
      },
      "id": "f959449c-8776-42ac-b776-3f564fafc331",
      "initial_processing_complete": true,
      "is_phone_submission": "2.0",
      "metadata": {
        "appVersion": "CommCare Android, version \"2.31.0\"(423345). App v18. CommCare Version 2.31. Build 423345, built on: 2016-11-02",
        "app_build_version": 18,
        "commcare_version": "2.31.0",
        "deprecatedID": null,
        "deviceID": "358001070684648",
        "doc_type": "Metadata",
        "geo_point": null,
        "instanceID": "f959449c-8776-42ac-b776-3f564fafc331",
        "location": null,
        "timeEnd": "2016-11-29T14:50:41.156000",
        "timeStart": "2016-11-29T14:50:36.155000",
        "userID": "e7ad965c70802884a7a67add763939e8",
        "username": "simon"
      },
      "problem": null,
      "received_on": "2016-11-29T14:50:42.530616Z",
      "resource_uri": "",
      "type": "data",
      "uiversion": "1",
      "version": "18"
    }
  ]
}