ActiveSoul Event Gateway

Overview

The ActiveSoul Event Gateway ("Gateway") gives event registration companies and event directors the ability to upload all their events to the ActiveSoul Platform. This exposes their events to tens of thousands of users in the ActiveSoul Network and boosts exposure and traffic to events. The ActiveSoul partnership with Wellness companies offers two huge benefits: 1) wellness members now see your event through their wellness programs and 2) wellness members have incentive to participate in your event since they get credit with their wellness program.

The Gateway includes an API that is HTTP-based, so it works with any language that has an HTTP library. Requests use standard HTTP verbs such as GET, POST, and DELETE. JSON is returned and accepted by all endpoints. The API documentation uses the JSON data types defined by W3Schools. The resource documentation describes requests and responses in detail for each endpoint.

Getting started

Step 1: Contact us to become an ActiveSoul Network Partner.

Step 2: Get your API key, client key, and client secret for our development environment.

Step 3: Begin coding your integration.

Step 4: Use your ActiveSoul Sandbox to develop and test your integration.

Step 5: Complete your integration.

Step 6: Perform a Launch Checklist Review with ActiveSoul.

Step 7: Get your API key, client key, and client secret for production.

Authentication

The API uses API keys and basic access authentication. Once you become an approved ActiveSoul Network Partner, you will receive an API key, a client key, and a client secret. To make a successful API call:

1. Pass your API key as an API-Key header.

2. Pass the client key and client secret as an Authorization header.


Base URL

https://www.activesoul.us/api/event/v1/Method.asp

Sandbox / Testing

Once you have access to the Affiliate API, ActiveSoul will provide sandbox authentication information.

The sandbox site is for testing and structured in exactly the same way as the production site. You will have full access to the API for development and testing purposes; you can experiment with changing settings and data.

After you have tested and finalized your integration, ActiveSoul will give you access to the production system. When you are ready to go live, contact our developer support team.


Sandbox Base URL

https://www.activesoul.us/api/event/sb/api/v1/Method.asp

API Calls

The API is HTTP-based, so it works with any language that has an HTTP library. Requests use standard HTTP verbs such as GET, POST, and DELETE. JSON is returned and accepted by all endpoints. The API documentation uses the JSON data types defined by W3Schools. The resource documentation describes requests and responses in detail for each endpoint.

All calls require an APP_ID and APP_SECRET for authentication, contact us to setup an account and get your authentication info

The format of calls is as follows. Note "method" is the specific method you are calling such as EventGet and this determines additional parameters for each method.

JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "method"
   ...additional parameters...
}


Return JSON:

Data is returned in the below format and specific data depends on the method. Every call returns "status" and "method", "status" is either "success" or "failed", refer to Error Handling for error codes when status returns "failed".

{
   "status":"success",
   "method":"EventGet",
   ...additional return data...
}

EventGet

This method returns a single event information based on the parameter "eventID". Parameters that are not self explanatory include:

      event_cnt : number of events returned, in this case this value is 1
      live : 0 event is "not live", 1 event is "live", 2 event is "deleted". Only live events appear on the site and in search results.


JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "GetEvent"
   "eventID": xxxx
}

Return JSON:

{
   "status":"success",
   "method":"EventGet",
   "event_cnt":1,
   "events":[
   {
   "eventID":4835,
   "name":"Event name",
   "address":"Event address",
   "city":"City",
   "state":"ST",
   "zip":"12345",
   "date":"5/4/2013",
   "distance":"5k, 10k",
   "live":1,
   "lat":26.1282229,
   "lng":-80.353367,
   "custom_url":"http://yourevent.com",
   "url":"http://www.runningguru.com/Event.asp?eID=4997"
   }
   ]
}

EventGetAll

This method returns all events for the race director in date order. Parameters that are not self explanatory include:

      event_cnt : number of events returned
      live : 0 event is "not live", 1 event is "live", 2 event is "deleted". Only live events appear on the site and in search results.


JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "GetEventAll"
}

Return JSON:

{
   "status":"success",
   "method":"EventGetAll",
   "event_cnt":2,
   "events":[
   {
   "eventID":4835,
   "name":"Event name 1",
   "address":"Event address",
   "city":"Canon City",
   "state":"CO",
   "zip":"12345",
   "date":"5/4/2013",
   "distance":"5k, 10k",
   "live":1,
   "lat":26.1282229,
   "lng":-80.353367,
   "custom_url":"http://yourevent.com",
   "url":"http://www.runningguru.com/Event.asp?eID=4835"
   },
   {
   "eventID":4997,
   "name":"Event name 2",
   "address":"Event address",
   "city":"Sunrise",
   "state":"FL",
   "zip":"12345",
   "date":"3/24/2013",
   "distance":"5k",
   "live":1,
   "lat":26.1282229,
   "lng":-80.353367,
   "custom_url":"http://yourevent.com",
   "url":"http://www.runningguru.com/Event.asp?eID=4997"
   }
   ]
}

EventAdd

This method adds an event to the calendar. Note the "eventID" of the added event is returned, this "eventID" will be used in other methods such as EventUpdate, EventDelete, EventStats, etc.

JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "EventAdd"
   "name":"Event name",
   "address":"Event address",
   "city":"Event city",
   "state":"xx",
   "zip":"xxxxx",
   "date":"mm/dd/yyyy",
   "distance":"5k, 10k",
   "custom_url":"http://www.yourevent.com"
}

Return JSON:

{
   "status":"success",
   "method":"EventAdd",
   "eventID": 1234,
   "live": 1,
   "url":"http://www.runningguru.com/Event.asp?eID=eventID"
}

EventUpdate

This method updates the event specified by "eventID" (which is returned when EventAdd is called). Take care as this will overwrite the existing data in the event.

JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "EventUpdate"
   "eventID": 1234,
   "name":"Event name",
   "address":"Event address",
   "city":"Event city",
   "state":"xx",
   "zip":"xxxxx",
   "date":"mm/dd/yyyy",
   "distance":"5k, 10k",
   "custom_url":"http://www.yourevent.com"
}

Return JSON:

{
   "status":"success",
   "method":"EventUpdate",
   "eventID": 1234,
}

EventDelete

This method sets the event status to "deleted".

JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "EventDelete",
   "eventID": xxxx
}

Return JSON:

{
   "status":"success",
   "method":"EventDelete",
   "eventID":xxxx,
   "live":2
}

EventStatusSet

This method sets the event status based on the parameter "live". Parameters that are not self explanatory include:

      live : 0 event is "not live", 1 event is "live".

Only live events appear on the site and in search results.


JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "EventStatusSet",
   "eventID": xxxx,
   "live": 0
}

Return JSON:

{
   "status":"success",
   "method":"EventStatusSet",
   "eventID":xxxx,
   "live":0
}

EventStats

This method returns the event stats based on the parameter "eventID".

JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "EventStats,"
   "eventID": xxxx
}

Return JSON:

{
   "status":"success",
   "method":"EventStats",
   "eventID":xxxx,
   "views":1234
}

UserGetInfo

This method returns your user information using app_id and app_secret.

JSON format:

{
   "APP_ID": "app_id",
   "APP_SECRET": "app_secret",
   "method": "UserGetInfo"
}

Return JSON:

{
   "status":"success",
   "method":"UserGetInfo",
   "name":"Your name",
   "company":"Your company",
}

Error Handling

To help reduce troubleshooting, the ActiveSoul API returns error codes in response to invalid or improperly formatted requests. When an invalid API request is made, the error codes can be used to identify and resolve issues like invalid parameters or conflicting site settings.

When an error occurs, the format of the return is as follows:

{
   "status":"failed",
   "errorCode":#,
   "errorDesc":"Description"
}

Status has the value "success" when calls succeed, and "failed" when an error occurs.

Error codes and descriptions are defined as follows:

Error Code Description
100 Invalid JSON format
101 Unknown method
200Invalid app_id and app_secret combination
201Not authorized to access event
300 Event not found
301 Invalid eventID value
302 Invalid live value

Testing

Use your app_id and app_secret to test calls.

Method:

App_id:  

App_secret:  

 UserInfoGet     EventGet     EventGetAll     EventAdd     EventUpdate     EventDelete     EventStatusSet     EventStats   

Click to execute

JSON Call:

JSON Return: