Prerequisites
Before using these APIs, configure authentication as described in Mobile Authentication.Create Support Ticket
Creates a support ticket for issues requiring human assistance. Endpoint:POST /api/sdk/v1/tickets
Content-Type: multipart/form-data
Request Fields
Response
Custom Fields Format
File Upload Constraints:
Contact Form Integration
The contact form system provides dynamic, configurable forms for ticket creation with custom fields, conditional logic, and progressive display.Overview
The contact form allows you to:- Fetch dynamically configured form structures from the server
- Display custom fields based on your ticketing system configuration
- Handle conditional field visibility (fields that appear based on other field values)
- Manage hidden fields that should be submitted but not displayed
- Implement progressive disclosure (fields appear as previous fields are completed)
- Collect email addresses from anonymous widget users
Get Form Configuration
Fetch the form configuration before displaying the contact form. Endpoint:GET /api/sdk/v1/config
Response Structure
Field Types
Field Display Logic
Hidden Fields (isHidden: true)
Hidden fields should be rendered as hidden inputs. Their values must be submitted with the form, but they should not be visible to the user.
Conditional Fields
Fields can be conditionally displayed based on the value of another field usingconditionalFieldId and conditionalFieldValue.
- Field A: “Issue Type” (dropdown: Bug, Feature Request, Question)
- Field B: “Bug Severity” (dropdown: Low, Medium, High)
conditionalFieldId: ID of Field AconditionalFieldValue: “Bug”- This field only appears when “Bug” is selected in Field A
Progressive Field Display
Fields appear progressively based on form completion:- Subject field (if
showSubjectis true) - Typology field appears after subject is filled (if
showTypologyis true) - Priority field appears after typology is filled (if
showPriorityis true) - Custom fields appear sequentially after priority is filled
- Each subsequent custom field appears after the previous field is completed
Field Options
Options in select fields can have special properties:Email Collection for Widget Users
When using widget authentication, the system creates anonymous users with email formatunknown_ago@{widget-id}.com. To collect the user’s real email:
- Check if the user is anonymous (email starts with
unknown_ago@) - Show an email input field in your form
- Validate the email format
- Pass the email in the
user_emailfield when submitting the ticket
Swift (iOS) Implementation
Kotlin (Android) Implementation
Best Practices
Related Documentation
- Mobile Authentication - Authentication setup
- Mobile Messaging API - Send and receive messages
- Mobile SDK Examples - Complete implementation examples
- Form Configuration API - Full form configuration reference
- Ticketing API - Complete ticketing API reference
