AskNicely's API allows you to programmatically add contacts, attach custom data, and trigger surveys. Whether you're importing a single contact or syncing a bulk list, the API provides powerful flexibility for developers looking to automate survey distribution.
💡 Introduction
If you’re using AskNicely in tandem with your internal systems or CRM and want complete control over how contacts are created and surveyed, our API is the best tool for the job.
This article focuses on two core endpoints:
Send Survey – import and survey a single contact
Bulk Add/Send – import and (optionally) survey multiple contacts
📎 Navigate in-platform:
Settings > API or visit yourdomain.asknice.ly/help
✉️ Send Survey Endpoint (Single Contact)
Use this to import one contact and send them a survey immediately. It’s a POST request sent to:
Required Parameters:
X-apikey– your account API keyname– full name of the contactemail– valid email address
You can also include any custom data fields (like city, company, segment, etc.).
🔧 Example Request:
Video Example...
📦 Bulk Add/Send Endpoint (Multiple Contacts)
Use this endpoint to import a batch of contacts, with the option to send surveys immediately.
Endpoint URL:
Requirements:
A valid JSON object containing a top-level
contactsarrayOptional: include
"obeyrules": trueif you want to apply Global Contact Rules and trigger surveys on send. Removing"obeyrules": truewill only import."obeyrules":false is not a valid option.
🔧 Example JSON:
📎 Visit your custom docs at:https://yourdomain.asknice.ly/help/bulkasync
Video example...
❓ FAQs & Common Issues
Q: Where do I find my API key?
A: Go to Settings > API inside AskNicely. Your key is listed at the top of the page.
Q: What happens if a contact already exists?
A: The API will update the existing contact with any new custom data provided.
Q: Can I trigger a survey and obey the Global Contact Rule?
A: Yes—add obeyrules:true in your Bulk Add/Send JSON request to apply Contact Rules.
Need help setting up your API connection? Contact our Support Team via chat or email support@asknice.ly.