Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Published by Scroll Versions from this space and version 1.2

Last Updated:

Lastupdatedate

Livesearch
placeholderSearch the Vibes Developer Wiki
typepage



Anchor
getallsubscriptionlists
getallsubscriptionlists
Get All Subscription Lists

The following will return all the Subscription Lists in the Mobile Database for the specified company.

Code Block
GET /companies/:company_id/mobiledb/subscription_lists


Note
Note: To get your company ID, please contact your Vibes account manager.

Request JSON

There is no Request JSON with a GET.

Return JSON

The following is an array of Subscription List objects for the specified company.

Code Block
[
   {
      "id":"ABC12345",
      "name":"Wonderful Subscription List",
      "url":"/companies/:company_id/mobiledb/subscription_lists/ABC12345",
      "subscribers_url":"/companies/:company_id/mobiledb/subscription_lists/ABC12345/subscribers",
      "acquisition_campaigns_url":"/companies/:company_id/mobiledb/subscription_lists/ABC12345/acquisition_campaigns"
   },
   {
      "id":"ABC123",
      "name":"Discount Offers List",
      "url":"/companies/:company_id/mobiledb/subscription_lists/ABC123",
      "subscribers_url":"/companies/:company_id/mobiledb/subscription_lists/ABC123/subscribers",
      "acquisition_campaigns_url":"/companies/:company_id/mobiledb/subscription_lists/ABC123/acquisition_campaigns"
   }
]

Anchor
getsubscriptionlist
getsubscriptionlist
Get Subscription List

The following will return the Subscription List object for the specified ID.

Code Block
GET /companies/:company_id/mobiledb/subscription_lists/:subscription_list_id

Request JSON

There is no Request JSON with a GET.

Return JSON

The Subscription List object.

Code Block
{
  "id": "12345",
  "name": "ExampleSubscriptionListObject",
  "url": "/companies/:company_id/mobiledb/subscription_lists/12345",
  "subscribers_url": "/companies/IuwDev2W/mobiledb/subscription_lists/1/subscribers",
  "acquisition_campaigns_url": "/companies/:company_id/mobiledb/subscription_lists/12345/acquisition_campaigns"
}


Note
Note: A 404 - Not Found error will be returned if the Subscription List could not be located.

Anchor
getacquisitioncampaigns
getacquisitioncampaigns
Get Acquisition Campaigns

The following will return an array of active Acquisition Campaign references that point to the specified Subscription List.

Code Block
GET /companies/:company_id/mobiledb/subscription_lists/:subscription_list_id/acquisition_campaigns

Request JSON

There is no Request JSON with a GET.

Return JSON

Code Block
{
    "acquisition_id": "R2Av0HaY",
    "description": "Example",
    "campaign_type": {
      "code": "ACQUISITION"
    },
    "status": "past",
    "start_date": "2015-10-24T15:15:05Z",
    "end_date": "2016-10-02T15:14:57Z",
    "created_date": "2015-10-24T15:15:05Z",
    "updated_date": "2016-10-02T15:14:58Z",
    "acquisition_campaign": {
      "keywords": [
        "EXAMPLETEAM"
      ]
    },
    "sourcecode": "12345",
    "url": "/companies/:company_id/campaigns/acquisition/R2Av0HaY"
  },


Note
Note: A 404 - Not Found error will be returned if the Subscription List could not be located.

Anchor
searchforsubscriber
searchforsubscriber
Search for Subscriber

Code Block
GET /companies/:company_id/mobiledb/subscription_lists/:subscription_list_id/subscribers?person_id=:person_id \\
GET /companies/:company_id/mobiledb/subscription_lists/:subscription_list_id/subscribers?external_person_id=:external_person_id \\
GET /companies/:company_id/mobiledb/subscription_lists/:subscription_list_id/subscribers?mdn=:mdn

This will search for a Subscriber on the specified Subscription List by person_id, external_person_id or MDN.

Request JSON

There is no Request JSON with a GET.

Return JSON

The following returns the Person object that was located.

Code Block
{
   "person_id":"AB3423",
   "external_person_id":"542342",
   "mobile_phone":{
      "mdn":"+12995551234",
      "carrier_code":"104"
   },
   "custom_fields":{
      "first_name":"Steve",
      "rewards_id":"543557654",
      "favorite_stores":[
         {
            "id":"4",
            "name":"My Hardware Store"
         },
         {
            "id":"12",
            "name":"Local Grocery"
         }
      ]
   },
   "created_at":"2017-01-15T14:30Z",
   "updated_at":"2017-02-18T19:30Z",
   "url":"/companies/:company_id/mobiledb/persons/:person_id"
}


Note
Note: A 404 - Not Found error will be returned if the Subscription List could not be located or if the specified Person is not subscribed to the list.