Use this call to get definitions of form templates used for Form-Based Messaging. The returned data of field names only includes HTML fields for some element types, which includes fields of types "input" and "textarea."
Request Data
Required Information | |
---|---|
Name | Description |
action | twentytwenty |
operation | getformdefinitions |
sourcename | Name of form source type.
Contact Customer Care to get the sourcename. |
direction | What type of form to describe; either sent by "dispatcher" or "driver" |
Optional Information | |
extids | comma-separated list of external IDs of the form templates to be described. |
Example Request
https://omi.zonarsystems.net/interface.php?customer=zzo2544&username=zonar&password=secret.pw.2019&action=twentytwenty&operation=getformdefinitions&sourcename=sourceName&direction=driver
Data Returned
JSON list of JSON dictionaries containing the following keys:
- "extid"
- "name"
- "description"
- "field_names"
"field_names" are the names of fields that are of type "<input />" and "<textarea />", which excludes labels and other static information.
Example Reply (JSON)
[
{
"extid": "abc",
"name": "Load",
"description": "Add a load",
"field_names": ["loadid", "cargo"]
}
]