Fields define what the data your form expects should look like. They are great security and validating feature but are not required.

Let’s say you wanted to create a contact form for your site. And the data your form was collecting were an email, name, and maybe a massage the user had for you.

So you would have one field for the email, one for the name, and one for the massage.

Given this, the API will expect the incoming data to look like the following.

{
"name":"abc",
"email":"[email protected]",
"massage":"hello there, I'm a big fan!"
}

<aside> ⚠️ If the incoming data is more than the number of fields, the API will deny the request. i.e: if you had one field for emails only but the incoming data contained an email and a name, the API will deny the request. This keeps your forms predictable.

</aside>

Required vs. Not Required

Required fields are fields the API will require in order to accept the incoming data.

For example, if you set the email field required, the API would deny any requests that do not contain data for that field.


Non-required fields are the exact opposite of required fields. The API won’t care if data was provided for them or not.