INCLUDED PLAN: This is only available on our ENTERPRISE plan
What is the API Field Name?
- The API FIELD NAME is a feature that works with the advanced API "addregistrations" when passing the "TaskResponses" JSON.
- When creating CUSTOM FORMS (a type of YouLi TASK RESPONSE), you will see the option to set an API FIELD NAME value for a custom field.
- If you maintain a Traveler portal that allows your Travelers to register profile information, use this feature to pass that information along with the registration to a TRIP.
- This saves the Traveler from having to re-enter information, like passport, dietary preferences, etc.
How to Set?
Within a CUSTOM FORM (TASK) when adding or editing a field, just below the "REQUIRED" checkbox there should be a field called API FIELD NAME where you can set the value you must reference in the API.
NOTE: This only appears for Custom Forms when you have the Advanced API Enabled.
- Once set, it cannot be changed
- The value must be unique across all fields for the same TRIP/TEMPLATE
- Only letters, numbers, underscore and dashes can be used to name API fields
- The API FiELD NAME is not required when creating the form, but if it is not set, that field cannot be used in the addregistrations API call
To make the best use of this feature, create your CUSTOM FORMS (with API FIELD NAMES) on a TEMPLATE and then ensure all your TRIPS are made from that Template. That will ensure your API calls are successful since all the fields will have the correct API FIELD NAMES.
I am passing the field value but the task is not completed
- Make sure you are providing all required fields for the TASK, otherwise the Task will not be completed and saved.
- Check the warnings returned by the addregistrations call to see if this is the problem.
- Make sure your API FIELD NAMES in the addregistrations API call match the values set in the CUSTOM FORM field.
I am not able to set the API Field Name
- Make sure it is unique for ALL custom fields across all TASKS in this TRIP/TEMPLATE.
- Make sure you don't have special characters or spaces in the name.
I need to change the API Field Name
Once set, the API FIELD NAME cannot be changed. But you can delete the field and make a new one with the new name.
Need more help?
For more tips on pre-trip customer support join the YouLi community of travel professionals with monthly LIVE webinars and Q&A sessions.