New Articles

  1. sgapiRemoveContactFromList(%%listID, %%email)

    This function removes a contact from a Contact List. Example In the below example we remove the contact specified in question ID 10 from an existing Contact List inside the Contact Management system. %%listid = 116; %%email = sg...
  2. sgapiEmailSend

    This function constructs and sends an email at the runtime of your custom script. sgapiEmailSend(%%to, %%toName, %%from, %%fromName, %%subject, %%textBody, %%htmlBody, %%bcc, %%mailReplyTo, %%type, %%attachments) Parameters* %%...
  3. sgapiSetTEXTEmail(%%questionID,%%value,%%language)

    This function sets the content of the TEXT version of a send email action. Parameters %%questionID - The ID of the send email action for which you are specifying content. %%value - The content you wish to use (string). %...
  4. sgapiAddContactToList(%%listID, %%email, %%fields, %%customfields)

    Our Email Lists allow account administrators to manage contacts for email lists at an account level. This function adds a new contact or updates an existing contact inside of a Contact List (as opposed to an email campaign). Parameters ...
  5. sgapiSetHTMLEmail(%%questionID,%%value,%%language = "English")

    This function sets the content of an HTML version of a send email action. Parameters %%questionID - The ID of the send email action for which you are specifying content. %%value - The content you wish to use (string). ...
  6. Email Campaigns & Actions

    These functions manage your email contact lists, create email content and trigger send email actions. sgapAddContactToInvite - This function adds the given contact to the given invite. sgapiRemoveContactFromInvite - This function...
  7. sgapiAddContactToInvite(%%linkID, %%email, %%fields, %%customfields, %dupsok)

    This function adds a contact with the list of given fields to the given invite. %%linkID* is the Invite ID of your email campaign %%email * is the email address of the contact you'd like to add %%fields is an array of the conta...
  8. sgapiListRemove(%%surveyID, %%responseID)

    This function removes the given response from the given survey. This is equivalent to deleting a SurveyResponse object via the RestAPI. To learn more visit the SurveyResponse API Object documentation. Example The below example removes...
  9. sgapiList(%%surveyID, %%page, %%countperpage, %%filterstring)

    This function returns the list of responses for the given survey. This is equivalent to a get list on the SurveyResponse object via the RestAPI. To learn more visit the SurveyResponse API Object documentation. Parameters %%page -...
  10. sgapiListAdd(%%surveyID, %%item)

    This function posts a response to the given survey using the array of items. This is equivalent to creating a SurveyResponse object via the RestAPI. To learn more visit the SurveyResponse API Object documentation. Example The below example scri...