Campaign

Objects

Campaign object

Attribute Description
walletId your tenant ID. e.g. JANUS
campaignId Identifier of the campaign e.g. 38ADC18674E344888F6EBB557E328395
campaignName Name of the campaign. e.g. Geofence CMP
campaignState State of the campaign. Possible values are CREATED, EXECUTED, PENDING and DELETED.
cretDtim Date and time that the campaign is created.
Format is yyyy-MM-dd’T’HH:mm:ss.SZ
e.g. “2019-02-08T14:23:35.443-0500”
yyyy: Year, e.g. 1996 <br>MM: Month in year, e.g. 07
dd: day in month, e.g. 10
HH:hour in day(0-23), e.g.0
mm:Minute in hour, e.g. 30
ss: Second in minute, e.g. 50
S: Millisecond in the minute, e.g. 443
Z: Timezone offset in hours(RFC 822 pattern), e.g. -0800
contentType Content type of the campaign. (Coupon or Advertisement) i.e. OFFER_GROUP, ADVERTISEMENT_GROUP
contentId Content id of the campaign. Offer group ID or advertisement group id.
periodStartDtim Campaign period start date/time.
Format is yyyy-MM-dd’T’HH:mm:ss.SZ
e.g. “2019-02-08T14:23:35.443-0500”
yyyy: Year, e.g. 1996 <br>MM: Month in year, e.g. 07
dd: day in month, e.g. 10
HH:hour in day(0-23), e.g.0
mm:Minute in hour, e.g. 30
ss: Second in minute, e.g. 50
S: Millisecond in the minute, e.g. 443
Z: Timezone offset in hours(RFC 822 pattern), e.g. -0800
periodEndDtim Campaign period end date/time.
Format is yyyy-MM-dd’T’HH:mm:ss.SZ
e.g. “2019-02-08T14:23:35.443-0500”
yyyy: Year, e.g. 1996 <br>MM: Month in year, e.g. 07
dd: day in month, e.g. 10
HH:hour in day(0-23), e.g.0
mm:Minute in hour, e.g. 30
ss: Second in minute, e.g. 50
S: Millisecond in the minute, e.g. 443
Z: Timezone offset in hours(RFC 822 pattern), e.g. -0800
executionDtim Campaign executed date/ time.
Format is yyyy-MM-dd’T’HH:mm:ss.SZ
e.g. “2019-02-08T14:23:35.443-0500”
yyyy: Year, e.g. 1996 <br>MM: Month in year, e.g. 07
dd: day in month, e.g. 10
HH:hour in day(0-23), e.g.0
mm:Minute in hour, e.g. 30
ss: Second in minute, e.g. 50
S: Millisecond in the minute, e.g. 443
Z: Timezone offset in hours(RFC 822 pattern), e.g. -0800
periodCostValue Monetary value which ends the coupon campaign. The campaign discontinues when the total coupon redemption monetary value reaches the configured value.
periodRedemptionCnt Redemption count which ends the coupon campaign. The campaign discontinues when the total number of redemption reaches the count.
segmentIdList List of user segment applied to the campaign. This is set when the campaign is user segment based campaign. Only users fall in the configured segments can see the coupons or advertisements.
campaignEventList List of campaign event applied to the campaign. This is set when the campaign is event driven campaign. It applies only to coupon campaign and when qualifying event is occurred, a coupon from the offer group is shown to the user.
Child Attributes
Attribute Description
walletEventId Identifier of wallet event defined for campaign.
Possible values are
- 1000: Customer signup. General event type.
- 1100: Loyalty program opt in. General event type.
- 1600: SVA purchased. Threshold amount is provided in eventParamValue.
- 1900: Birthday. General event type.
- 2000: Signup anniversary. General event type.
- 2100: SVA gift. Threshold amount is provided in eventParamValue.
- 2200: Location based event. Geofencing info is provided in eventParamValue.
- 2300: Promocode. Valid promo codes are provided in eventParamValue.
- 2400: Beacon. Valid beacon ID list is provided in eventParamValue.
rewardedLoyaltyPointsQty Corresponding detail configuration for a walletEventId in JSON format. e.g.
- {"eventId":"1000","type":"general"}
- {"eventId":"1600","overDollars":50,"type":"sva"}
- {"eventId":"2100","overDollars":50,"type":"sva"}
- {"eventId":"2300","promoCodes":["abc"],"type":"promocode"}
- {"eventId":"1100","type":"general"}
- {"eventId":"2000","type":"general"}
- {"type":"sva","eventId":"2100","overDollars":20.0}
- {"eventId":"2200","distance":1.0,"type":"geofencing","coordinateList":[{"lat":34.0452953,"lon":-84.33333379999999}],"dupEventTheshold":"EVERYTIME"}
- {"beaconIds":["beconid1"],"eventId":"2400","type":"beacon"}
- {"eventId":"1900","type":"general"}
eventType Type of the campaign event.
e.g. general, geofencing, sva, promocode, beacon

APIs

Get list of geofencing based campaigns

Retrieves your pre-defined list of geofencing based campaigns.

Precondition

Client logged in the service. Refer the section for registration/authentication.

Request

HTTP Method / URL
POST / http://api-dev.fintiv.co:8080/campaign/{version}/getGeofencingCampaignList

Body parameters
None

Example request

curl -X POST "http://api-dev.fintiv.co:8080/campaign/v2/getGeofencingCampaignList"
-H "accept: application/json;charset=UTF-8"
-H "api-key: <insert your APP Key here>"
-H "authorization: Bearer <insert your bearer token here>"
-H "Content-Type: application/json"
-d ‘{ }’

Response

Returns list of geofencing campaigns.
Example response

{
  "result": {
    "code": 0
  },
  "geofencingCampaignList": [
    {
      "campaignId": "38ADC18674E344888F6EBB557E328395",
      "geofenceInfoList": [
        {
          "lat": 0,
          "lon": 0,
          "distance": 1
        },
        {
          "lat": 34.0452953,
          "lon": -84.33333379999999,
          "distance": 1
        }
      ]
    }
  ]
}

Report the event that end user enters into the location of campaign

Client manages and monitor geofencing information of campaign. If the end user enters into the geofencing location, the client detects and reports the event to the server. Then the server will publish the associated campaign to the end user.

Precondition

Client logged in the service. Refer the section for registration/authentication.

Request

HTTP Method / URL
POST / http://api-dev.fintiv.co:8080/campaign/{version}/reportEnteringCampaignArea

Body parameters

Parameters Type Required Note
campaignIdList double Required Identifier of the campaign e.g. 38ADC18674E344888F6EBB557E328395
eventDtim double Required Event occurred date/time
Format is yyyy-MM-dd’T’HH:mm:ss.SZ
e.g. “2019-02-08T14:23:35.443-0500”
yyyy: Year, e.g. 1996 <br>MM: Month in year, e.g. 07
dd: day in month, e.g. 10
HH:hour in day(0-23), e.g.0
mm:Minute in hour, e.g. 30
ss: Second in minute, e.g. 50
S: Millisecond in the minute, e.g. 443
Z: Timezone offset in hours(RFC 822 pattern), e.g. -0800

Example request

curl -X POST "http://api-dev.fintiv.co:8080/campaign/v2/reportEnteringCampaignArea"
-H "accept: application/json;charset=UTF-8"
-H "api-key: <insert your APP Key here>"
-H "authorization: Bearer <insert your bearer token here>"
-H "Content-Type: application/json"
-d
‘{
             "campaignIdList": ["38ADC18674E344888F6EBB557E328395"],
             "eventDtim": "2019-02-16T00:00:00.000-0500"
}’

Response

Returns result of the request.

Example response

{
  "result": {
    "code": 0
  }
}

Report the event that beacon detected or promotion code used

Client manages and monitor beacon and promotion code information of campaign. If it detects a beacon ID or that the end user used a promotion code, the client detects and reports the event to the server. Then the server will publish the associated campaign to the end user.

Precondition

Client logged in the service. Refer the section for registration/authentication.

Request

HTTP Method / URL
POST / http://api-dev.fintiv.co:8080/campaign/{version}/reportCampaignEvent

Body parameters

Parameters Type Required Note
eventValue String Required Value of event. e.g. Actual value of Beacon ID or promotion code.
eventValueType String Required Type of event. Possible values are BEACON_ID and PROMO_CODE

Example request

curl -X POST "http://api-dev.fintiv.co:8080/campaign/v2/reportCampaignEvent"
-H "accept: application/json;charset=UTF-8"
-H "api-key: <insert your APP Key here>"
-H "authorization: Bearer <insert your bearer token here>"
-H "Content-Type: application/json"
-d
‘{
             "eventValue": "HAPPYMOM",
             "eventValueType": "PROMO_CODE"
}’

Response

Returns result of the request.
Example response

{
  "result": {
    "code": 0
  }
}