• Quick Start
  • Send Survey
  • Get Contact
  • Remove Contact
  • Delete Contact (GDPR)
  • Get Unsubscribed
  • Get Responses
  • Get NPS
  • Sent Statistics
  • Historical Stats
  • Deactivate All
  • Bulk Add with CSV
  • Inapp Surveys
  • Bulk Add/Send

Change Log

  • Changes

Get a list of all unsubscribed contacts

This will return a JSON array of customers that have manually unsubscribed from AskNicely surveys using our unsubscribe link on the footer of our emails

API Endpoint

Make a HTTPS GET request to https://DEMO.asknice.ly/api/v1/contacts/unsubscribed

Optional Arguments

Argument Type Example Required Description
pagenumber integer 1 optional Start querying the contacts from "pagenumber". This value should be greater than 0.
pagesize integer 1000 optional "pagesize" of rows will be returned in the response. This value should be greater than 0.

Example CURL call to get the JSON unsubscribed list

curl --header "X-apikey: " \
https://DEMO.asknice.ly/api/v1/contacts/unsubscribed

Example Request when using optional pagination

curl --header "X-apikey: " \
"https://DEMO.asknice.ly/api/v1/contacts/unsubscribed?pagenumber=1&pagesize=1000"

Note

  • Pagination is optional, if it is used, the parameter of "pagenumber" must to be set. If the parameter of "pagesize" is NOT set, by default, 1000 records are returned.
  • id in the JSON response (see below) is the contact ID, same as "contact_id" from Get Responses and the "id" returned by Send Survey.

Example Response

{
   "success":true,
   "data":[
     {
      "id":"15816",
      "unsubscribetime":"1452219376",
      "email":"test@example.com"
     },{
      "id":"16838",
      "unsubscribetime":"14522193485",
      "email":"test2@example.com"
     },
   ]
}