Live Push User Activity


Request Details

Item Value
Description Sends information about activity events for a member to a client specified endpoint.
Method POST
Endpoint Client provided, must begin with https://
Content Type application/json

Recommended Request Authentication

Field Name Sample Value Required Format Description
Basic

Username: test

Password: password123

Base64Auth

No String

Basic auth is the client provided username & password in Base 64 format.

The value of username:password is Base64 encoded.

x-api-key GRscvhg53SsDg1gxxsDgcsf123 No String x-api-key is the client provided API key for access to the defined endpoint

Multilanguage Support

  • The member’s preferred language (stored on their profile) is what determines the language of the provided values. This value is set via User Create API, User Update API or via widget.
  • The translated fields (translatedTitle, translatedDescription) will be null if either the user’s language is not set or if translations for the associated activity are not loaded into the CrowdTwist platform.

Request Body

Field Name Sample Value Required Format Description
userActivityId 12348765 Yes Integer Unique ID for the activity completion.
activityId 198 Yes Integer CrowdTwist activity ID
activityName added gender Yes String (200) Name of the activity performed
points 80 Yes Integer Number of points earned for the activity; positive for any added activity, negative for reward redeemed
notes null No String (4000) Limited to 4,000 characters, if longer will be trimmed to 3997 and appended with “…”
referenceId 123 No Integer CrowdTwist reference ID
activityExtraData {“apporderid”:”1”} No String (4000) Extra data stored within the activity configuration. Limited to 4,000 characters, if longer will be trimmed to 3997 and appended with “…”
thirdPartyId null No String (100) Member’s third party ID
title Add Your Gender Yes String (150) Title of the activity performed
description Add your gender and earn 50 points Yes String (500) Description of the activity performed
userId 101 Yes Integer CrowdTwist user ID

userName

johndoe23 Yes String Member’s username
emailAddress johndoe@gmail.com Yes String (200) Member’s email address
mobileNumber null No String (30) Member’s phone number
dateCreated 1438039473 Yes Integer Date/time the activity was processed (unix timestamp)
dateAwarded 1438039473 Yes Integer Date/time the activity was performed (unix timestamp)
userActivityCustomData   No

String (4000)

Currently null, included to future proof
languageId es Yes String (6) Preferred language for the member
translatedTitle Agrega tu género No String (150) Title of the activity performed, in the member’s preferred language (relative to languageId)
translatedDescription Agrega tu género y gana 50 puntos No String (500) Description of the activity performed, in the member’s preferred language (relative to languageId)


Sample Request

{
   "activityExtraData":"{\"location\": \" New York\"}",
   "activityId":215,
   "activityName":"added gender",
   "dateAwarded":"1541438256",
   "dateCreated":"1541438256",
   "description":"Add your gender and earn 50 points",
   "emailAddress":"johnsmith@gmail.com",
   "languageId":"fr",
   "mobileNumber":"659587925",
   "notes":"",
   "points":80,
   "referenceId":0,
   "thirdPartyId":"tbh375ht",
   "title":"Add Your Gender",
   "translatedDescription":"Agrega tu género y gana 50 puntos",
   "translatedTitle":"Agrega tu género ",
   "userActivityCustomData":null,
   "userActivityId":102,
   "userId":203,
   "userName":"johnsmith"
}