WebHook API for Publishers

Learn how to integrate our Eventport WebHook API for Publisher.

What are Webhooks?

Webhooks allow you to get information about events as they happen in near real-time. Just provide a URL and we'll send the data to you as the events take place.

To test our Webhook API before setting up scripts, the RequestBin tool is an excellent utility that helps you see data come across as various events happen in our system.

Configuring Webhooks

Webhooks are configured from your Eventport account. Here are the basic steps:

  1. Log in to your Eventport Publisher account
  2. Navigate to the API settings page
  3. Enter your WebHook URL and click "Save"
  4. Use the shown API Token to secure your WebHook endpoint.
    The API Token is sent as query parameter accessToken
  5. Test your integration with our testing tool.

Securing Webhooks

We currently support either HTTP or HTTPS urls, so you can have security by using an SSL-enabled url.

But keep in mind that your endpoint is going to be wide-open on the internet, and you might not want others to be able to submit random data to your systems. There are two ways to protect your endpoint from unauthorized access.

With each request we send your secret API Token as query parameter accessToken. You should check incoming request for this token.

We also support HTTP Basic Authentication. You can usually enable this in your webserver for the endpoint. You need to give us the username and password via the Webhook URL in the settings. For example: https://username:[email protected]/endpoint.

Testing the Integration

We have developed a tool for testing the Webhook API integration. You can find it in the settings in Eventport (login required).

Versioning

You can select the version in which you would like to receive data from us in your settings . As the API currently only has one version, there is not much for you to do right now.

We will tell you about new versions that you can upgrade to and we will warn you early enough if we decide to deprecate or abandon an old version.

Events API

The data is sent as JSON in a POST request.

Request formats

Requests are sent when an event is:

  • published
  • updated
  • cancelled

Out general format for requests is the following:

{
  "type": "event",
  "method": "post",
  "version": "1.0",
  "data": {
    "event": "<EventObject>",
    "profile": "<OrganizerProfileObject>"
  }
}
{
  "type": "event",
  "method": "cancel",
  "version": "1.0",
  "data": {
    "event": {
      "_id": "<eventId>"
    }
  }
}

Example Requests

Here are full examples of requests.

{
  "type": "event",
  "method": "post",
  "version": "1.0",
  "data": {
    "event": {
      "profileId": "tj4zTLeFTkAunsnMh",
      "autoUpdate": false,
      "name": "Event Title",
      "inlet": "2014-11-21T21:00:00.000Z",
      "begin": "2014-11-21T21:00:00.000Z",
      "end": "2014-11-22T01:00:00.000Z",
      "openEnd": false,
      "description": "",
      "genres": [],
      "types": [],
      "repeating": false,
      "location": {
        "_id": "tj4zTLeFTkAunsnMh",
        "name": "Eventport Testprofil",
        "street": "Trappentreustrasse 35",
        "postalcode": "80339",
        "city": "Munich",
        "homepage": "http://eventport.net",
        "facebookPageId": "785890424771022"
      },
      "floors": [],
      "mediaPartners": [],
      "lineup": [],
      "priceCategories": [],
      "tickets": [],
      "media": [],
      "rescheduled": false,
      "relocated": false,
      "cancelled": false,
      "channels": {
        "publisherNewsletter": {
          "description": "",
          "useGeneralDescription": true
        },
        "facebook": {
          "description": "",
          "useGeneralDescription": true,
          "postTimeType": 0,
          "postTime": "2014-11-21T21:30:00.000Z",
          "imported": false
        },
        "homepage": {
          "description": "",
          "useGeneralDescription": true,
          "customFields": {}
        }
      },
      "publisherReceivers": [],
      "publisherReceiverGroups": [],
      "userReceivers": [],
      "_id": "K8qjtKSegBfbdGppg",
      "changed": true,
      "changedOn": "2014-11-21T18:18:04.378Z",
      "organizer": "Eventport Testprofil"
    },
    "profile": {
      "_id": "tj4zTLeFTkAunsnMh",
      "name": "Eventport",
      "street": "Heßstrasse 89",
      "addressAddition": "",
      "postalcode": "80797",
      "city": "München",
      "phone": "+49 176 123 456",
      "email": "[email protected]",
      "homepage": "http://www.eventport.net",
      "facebookPageId": "459661150826745",
      "description": "This is our example profile for Eventport.",
      "counterparts": [
        {
          "name": "Max Mustermann",
          "phone": "+49 176 123 4567",
          "email": "[email protected]",
          "roles": ["Marketing"]
        }
      ]
    }
  }
}
{
  "type": "event",
  "method": "post",
  "version": "1.0",
  "data": {
    "event": {
      "profileId": "tj4zTLeFTkAunsnMh",
      "autoUpdate": false,
      "name": "Event Title 2",
      "inlet": "2014-11-21T21:00:00.000Z",
      "begin": "2014-11-21T21:00:00.000Z",
      "end": "2014-11-22T01:00:00.000Z",
      "openEnd": false,
      "description": "This is the event description.\n\nIt can have line breaks.",
      "genres": [
        "House",
        "Hip Hop"
      ],
      "types": [
        "Clubevent",
        "Party"
      ],
      "repeating": false,
      "location": {
        "_id": "tj4zTLeFTkAunsnMh",
        "name": "Eventport Testprofil",
        "street": "Trappentreustrasse 35",
        "postalcode": "80339",
        "city": "Munich",
        "homepage": "http://eventport.net",
        "facebookPageId": "785890424771022"
      },
      "floors": [
        "Dancefloor",
        "Lounge"
      ],
      "mediaPartners": [
        {
          "name": "Media Partner Name",
          "url": "https://www.google.com"
        }
      ],
      "priceCategories": [
        {
          "name": {
            "id": "PRESALE_PRICE",
            "text": "Pre-sale"
          },
          "price": 12,
          "hasProcessingFee": false,
          "conditions": "Limited to 500 tickets."
        },
        {
          "name": {
            "id": "BOX_OFFICE_PRICE",
            "text": "Box office price"
          },
          "price": 15,
          "hasProcessingFee": false
        }
      ],
      "tickets": [
        {
          "url": "http://eventim.de",
          "text": "Eventim"
        }
      ],
      "media": [
        {
          "url": "https://www.youtube.com/watch?v=48YDO2yN0JE",
          "text": "Random Video"
        }
      ],
      "rescheduled": false,
      "relocated": false,
      "cancelled": false,
      "channels": {
        "facebook": {
          "description": "This is the event description.\n\nIt can have line breaks.",
          "imported": false,
          "postTime": "2014-11-21T21:30:00.000Z",
          "postTimeType": 0,
          "useGeneralDescription": true
        },
        "homepage": {
          "customFields": {
          },
          "description": "<p>This is the event description. It can have line breaks.</p>",
          "publishedOn": "2014-11-21T18:18:12.986Z",
          "url": "ok",
          "useGeneralDescription": true
        },
        "publisherNewsletter": {
          "description": "This is the event description.\n\nIt can have line breaks.",
          "useGeneralDescription": true
        }
      },
      "publisherReceivers": [
      ],
      "publisherReceiverGroups": [
      ],
      "userReceivers": [
      ],
      "_id": "K8qjtKSegBfbdGppg",
      "changed": true,
      "changedOn": "2014-11-24T00:29:56.383Z",
      "embeddedCodes": [
        {
          "code": "<iframe width=\"560\" height=\"315\" src=\"//www.youtube.com/embed/48YDO2yN0JE\" frameborder=\"0\" allowfullscreen></iframe>",
          "title": "Random YouTube Video"
        }
      ],
      "organizer": "Eventport Testprofil",
      "preSaleBegin": "2014-11-20T00:00:00.000Z",
      "publishedOn": "2014-11-24T00:29:20.147Z",
      "remark": "A note for publishers."
    },
    "profile": {
      "_id": "tj4zTLeFTkAunsnMh",
      "name": "Eventport",
      "street": "Heßstrasse 89",
      "addressAddition": "",
      "postalcode": "80797",
      "city": "München",
      "phone": "+49 176 123 456",
      "email": "[email protected]",
      "homepage": "http://www.eventport.net",
      "facebookPageId": "459661150826745",
      "description": "This is our example profile for Eventport.",
      "counterparts": [
        {
          "name": "Max Mustermann",
          "phone": "+49 176 123 4567",
          "email": "[email protected]",
          "roles": ["Marketing"]
        }
      ]
    }
  }
}
{
  "type": "event",
  "method": "cancel",
  "version": "1.0",
  "data": {
    "event": {
      "_id": "tj4zTLeFTkAunsnMh"
    }
  }
}

📘

Documentation format

A type in brackets means that it is an array of this type.

EventObject

AttributeTypeLabel
_idStringEvent ID
profileIdStringProfile ID
nameStringEvent title
subtitleStringSubtitle
organizerStringOrganizer
remarkStringNotes for publishers
inletDateInlet date/time
beginDateBegin date and time
endDate
openEndBoolean
location._idString
location.nameString
location.streetString
location.addressAddictionString
location.postalcodeString
location.cityString
location.homepageString
location.facebookPageIdNumber
floors[String]
types[String]A list of event types.
genres[String]Music genres
descriptionString
mediaPartners[Object]
mediaPartners.$.nameString
mediaPartners.$.urlString
preSaleBeginDate
priceCategories[Object]
priceCategories.$.nameObject
priceCategories.$.name.idString
priceCategories.$.name.textString
priceCategories.$.priceNumber
priceCategories.$.hasProcessingFeeNumber
priceCategories.$.conditionsString
tickets[Object]
tickets.$.urlString
tickets.$.textString
photos[PhotoObject]Photos
documents[DocumentObject]Documents
media[Object]
media.$.urlString
media.$.textString
embeddedCodes[Object]
embeddedCodes.$.codeString
embeddedCodes.$.titleString
rescheduledBoolean
relocatedBoolean
cancelledBoolean
publishedOnDate
channels.publisherNewsletterObject
channels.publisherNewsletter.descriptionStringDescription for publishers
channels.publisherNewsletter.publishedOnDate
channels.publisherNewsletter.useGeneralDescriptionBoolean
channels.facebookObject
channels.facebook.idString
channels.facebook.postTimeTypeNumber
channels.facebook.postTimeDate
channels.facebook.descriptionStringDescription for facebook
channels.facebook.publishedOnDate
channels.facebook.useGeneralDescriptionBoolean
channels.facebook.photoIdString
autoUpdateBoolean

PhotoObject / DocumentObject

AttributeTypeLabelDescription
_idStringObject ID
urlStringPhoto / Document URL
thumbnailUrlStringPhoto thumbnail URLThis only for photos
purposes[String]Purposessee note below
titleStringTitle
Photo purpose IDDescription
0Photo avilable for publishers
1The photo should be used on the homepage
2The photo is used as Facebook cover photo
3The front side of the event flyer
4The back side of the event flyer
5The photo is used in the publisher newsletter
6The main photo for the homepage. Only one photo has this purpose.
Document purpose IDDescription
0Document should be used on the homepage
1Document avilable for Publishers

OrganizerProfileObject

AttributeTypeLabelDescription
_idStringProfile ID
addressAddictionStringAddress addiction
cityStringCity
counterparts[Object]Conterparts
counterparts.$.nameStringName
counterparts.$.phoneStringPhone number
counterparts.$.emailStringEmail address
counterparts.$.roles[String]Roles
descriptionStringDescription
emailStringEmail
facebookPageIdStringFacebook page ID
homepageStringHomepage
phoneStringPhone number
postalcodeStringZIP
streetStringStreet