This resource represents the questions and configurations of a form in your portal. Responses to forms are stored as Form Response entities.

Properties

This resource uses all common resource properties.

Form Questions are stored in the fields.formFields map, which is keyed by the ID of each question (stored in order in the fields.formFieldIDs array).

fields object

  • name string Title of the Form
  • description string (optional) Description of the Form
  • formFieldIds array(string) Array of IDs, each corresponding to a question ("form field") in the form, in the order that they are arranged in the form.
  • formFields array(FormField) Stores the content of each question (”form field”) in the form, in the order they are arranged in the form.
    • formFieldId: The ID of this form field, matching the corresponding entity in formFieldIds
    • title string The title of the question.
    • description string (optional) The description of the question.
    • type string Describes the type of this question. Options are: shortAnswer, longAnswer, multiSelect, singleSelect, title, fileUpload.
    • multipleChoiceOptions array(string) (optional) All the possible option values the user can select for this question. Only present on singleSelect and multiSelect questions.
    • isRequired boolean Whether the client is required to answer this question.
  • allowMultipleSubmissions boolean Whether clients can submit this form multiple times.
  • visibility string Whether this form is visible to all clients by default, or only clients that the form is directly shared with. Options are: allClients, requestedClients

additionalFields object

  • formResponseRequests number Number of clients who have been explicitly sent this form, and have not submitted it.
  • formResponseSubmissions number Number of times this form has been submitted (may include multiple submissions per client if allowMultipleSubmissions = true).
  • latestSubmissionDate string The time of the most recent client submission to this form.
{
    "id": "a8c2c520-8045-4068-1772-a7c8ca09ee1a",
    "createdAt": "2023-02-25T02:19:35Z",
    "object": "form",
    "fields": {
        "name": "Onboarding Form",
        "description": "Fill out this form to get started!",
        "formFieldIds": ["id0", "id1", "id2", "id3"],
        "formFields": [
            {
                "formFieldId": "id0",
                "title": "Welcome to Harry's Wizarding Consultancy!",
                "description": "Email me if you have any questions at [email protected]",
                "type": "title",
                "isRequired": false
            },
            {
                "formFieldId": "id1",
                "title": "What is your full name?",
                "description": "",
                "type": "shortAnswer",
                "isRequired": true
            },
            {
                "formFieldId": "id2",
                "title": "Upload your ID",
                "description": "You can upload multiple documents",
                "type": "fileUpload",
                "isRequired": true
            },
            {
                "formFieldId": "id3",
                "title": "Which services are you interested in?",
                "description": "",
                "type": "multiSelect",
                "multipleChoiceOptions": ["Taxes", "Family Accounting", "Advice"],
                "isRequired": false
            },
        ],
        "allowMultipleSubmissions": false,
        "visibility": "allClients"
    },
    "additionalFields": {
        "formResponseRequests": 3,
        "formResponseSubmissions": 8,
        "latestSubmissionDate": "2023-05-25T02:19:35Z"
    }
}