You may create a form directly if you have collected and validated all of the necessary data. Send a post request to the forms endpoint, and if it successfully posts, Nextform will respond with a complete form object, including the form ID, which can be used to obtain a PDF or to access the form data at any point in the future.
The body should be posted as raw JSON. The type must be specified, and the data property should include all of the required fields. Data will be tested for validity, and the post request will fail if it is not valid. The signatures array also must include a valid signature with the appropriate signing party for the form type. The below example demonstrates the minimum required properties, with the exception of the data property which will depend on the form type you are posting.
POST https://api.nextform.app/forms
{
"type": "w9Oct2018",
"data": {
"name": "Robert Smith",
"etc": "..."
},
"signatures": [
{
"consent": true,
"name": "Robert Smith",
"email": "user@example.com",
"party": "usPerson"
}
]
}
The endpoint responds with a fully hydrated form object, which will include the form ID and all available properties, whether they have been set or not.
{
"id": "7TXQXohQX6Eu3LvLEG1xvY",
"reference": null,
"type": "w9Oct2018",
"createdAt": "2021-12-15T19:31:12.170Z",
"data": {
"name": "Robert Smith",
"etc": "..."
},
"signatures": [
{
"id": "Q6HUpCzvzXGyuyUkGbJg9Q",
"reference": null,
"consent": true,
"name": "Robert Smith",
"email": "user@example.com",
"party": "usPerson",
"createdAt": "2021-12-15T19:31:12.229Z"
}
]
}
A string representing the type and version of the form. Official bodies revise forms from time to time. Our forms are designed to target a specific form type to avoid unexpected new or deprecated fields in the data object.
If you would like to attach a user ID or other unique identifier to the session, you may set a string up to 255 characters in length. The reference string may be queried via our list forms endpoint.
The data object must include all required properties from the specified form type. Refer to the form type guides for properties. Note that some of the properties are dependent upon eachoter.
This array should include at least one of the required signatures for the form type you are posting. See below for additional details about signatures.
A boolean indicating whether or not the individual consented to electronically sign the document. Signatures will not be posted unless the value is true.
The typed name of the signer.
The email address of the signer. This is required to enhance the attribution requirement of the eSign act.
A string indicating the party of the signer. Refer to the specific form type documentation to learn about the parties associated with each form.