Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Instructions for hosting an event on

Hosting a competition on adding an EVENT.json file to the root of your project.

Hosting an event on surge is very simple. It's three easy steps.

  1. Publish a project to Surge to your root domain (eg. surge ./myproject
  2. Point and * DNS records to surges servers.
  3. Add EVENT.json file with the following properties...
  "name"        : "Super Event",
  "start"       : "2016-05-03T09:00",
  "end"         : "2016-05-14T17:00",
  "twitter"     : "@superevent",
  "email"       : "",
  "webhook"     : "",
  "slackhook"   : ""

note: all EVENT.json values are optional

  • name the name of your event.
  • start when participants can begin to publish.
  • end when publishing closes.
  • twitter twitter account for event.
  • webhook webhook url for post publish hooks.
  • slackhoo slack web hook integration url

event creation on

Thats it. You are now hosting an event on surge!

Add a slackhook property to get super useful info into any slack channel you like.

slack message

Your participants can now publish to <subdomain>

-event participation on

note: Events work on root domains as well.

Example of a webhook server:

var http = require('http')
var express    = require('express')
var bodyParser = require('body-parser')

var app = express()

// parse application/json

app.use(function (req, res, next) {
  console.log(req.body) // output hook data!

console.log('Server running at')

Test your webhook server:

curl -H "Content-Type: application/json" -X POST -d '{"hello":"world"}'

This comment has been minimized.

Copy link

cfjedimaster commented Apr 28, 2016

What exactly do you mean by a competition though? When I saw event, my first thought was just that, an "event". So I have a static web site for a local children's museum and they are having an event next week. I'm guessing this isn't related to that at all?

What exactly is being sent to slack/webhook? You say notifications, but notifications of what exactly?

I feel like I'm missing something really obvious here. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.