Configure Form

Configure a form

The Configure Form endpoint creates a structure of form, which the driver can fill on site. the definition of any field is:

parametertypeDescription
keyStringname of field
labelStringdisplay label
typeNumbervalue type:
0 - NUMBER
1 - TEXT
2 - BOOLEAN
3 - LIST
controlNumberUI control
0 - INPUT
1 - CHECKBOX
2 - SWITCH
3 - RADIO
4 - DROPDOWN
mandatoryBooleandefine if the field is required
defaultValueObjectdefault value of field
list_valuesArraylist of options (only for type LIST)
curl --include \
     --request POST \
     --header "Content-Type: application/json" \
     --data-binary "{ \"title\": \"Form Title\", \"button_label\": \"Form Button Label\", \"enabled\": true, \"fields\": \"{\"key\":\"tow\",\"label\":\"Tow\",\"type\":2,\"control\":2},{\"key\":\"3\",\"label\":\"Windscreen wiper\",\"type\":2,\"control\":2},{\"key\":\"4\",\"label\":\"Scented tree\",\"type\":2,\"control\":2},{\"key\":\"price\",\"label\":\"Price\",\"type\":0,\"control\":0},{\"key\":\"description\",\"label\":\"Description\",\"type\":1,\"control\":0}]\", \"timestamp\":\"1414421210832\", \"access_token\":\"K2Pxkwvx6-3PtW44zvEV\", \"signature\":\"db00061fa75f869c968f72d48449e457ae06959a\"}" \
https://api.bringg.com/partner_api/companies/{id}/form
Language