Okie.io: #matchurl.com

Okie.io: #matchurl.com


I think I've been looking for an excuse to play with some NodeJS and SocketIO as well as write a webapp using Express. I'm definitely not against making another chat app, but I wanted something different this time around.

I was listening to the ShopTalk Show on 5by5 and saw Ryan Singer show off his new project: http://okie.io . It looked pretty awesome and it's still really early in development so this seemed like a good opportunity to help out.

The basic idea is that you host an instance of Okie.io (or use one of the pre-made options) and you can make simple status updates from your browser or mobile phone by sending short messages over websockets (or polling for them if you absolutely must).

Your update gets pushed to all users who are currently online. If someone updates their message, those changes will be pushed out as soon as Okie.io receives them (unless the user turns off "fast mode").

Ryan's original example uses the GoPro API to update your status with what camera/lens/etc you're using on an outing, but I see no reason why this couldn't be used for any sort of activity. I would like to experiment with some fun ideas like location based statuses or group chats in the future. For now, it works pretty well.

I've also made a useful addition that allows you to define custom commands within your status updates by starting them with a special character. Usernames are denoted by an "@" symbol, but there are other options too (I'll leave it to you to discover them).



Okie.io is hosted on Heroku at the moment which means that you can push your own instance with a single git push! Of course, you could easily just deploy this yourself if you have some knowledge of NodeJS and Express or simply want to hack around with it on your local machine.

The only non-standard library I'm using is SocketIO which requires compiling native modules for NodeJS without NPM support. If anyone knows how I can get rid of this requirement please let me know . Other than that, npm install express should get everything ready to go.

The default user/password combination is: admin / okie . You can change that in client.js and then restart the server if you like, but I might reset this to the original password at some point (so don't use it for anything important).

You can also run another instance of Okie.io on your machine and connect them together using Websockets or NodeJS's built-in SocketIOServer (example included in "client" folder).

Current Features

Some features are still a work-in-progress, such as adding private statuses which allows you to define who sees your updates without having to bother with social networks or other types of authentication. For now, anyone online will see your updates and you can easily set a status that is private. Using the aforementioned custom commands feature, I've also created two special commands: "/login" and "/logout".

You can try them out by starting with "@login" or "@logout", but if anyone actually makes use of these features I'll probably add some sort of proper authentication system (if it becomes too much of a problem).


Okie.io is really impressive in my opinion! If you still think this article is helpful, please recommend :) Also, feel free to share your thoughts in the comments below or checkout Ryan Singer's original blog post here . Thanks for reading and happy Okie-ing! ;) P.S. - If you have any questions, don't hesitate to ask! I'm around here somewhere...


Okie.io is a realtime status sharing platform similar to Twitter's TweetDeck but much easier to use and has many cool features. In this tutorial we will install Okie.io on our machine, configure it for our server and then push some updates from the command line using NodeJS SocketIO package. We'll also see how we can connect two instances of Okie.io together to create a Twitter-like experience between friends! Let's start with the installation guide:

First, make sure you have NodeJS installed on your machine. If not, download it from here . Okie.io requires version 0.10 or higher of NodeJS.

Then install the SocketIO package for NodeJS (if you don't know what is SocketIO , think of it as WebSockets but better). Just open up your console and type:

npm install socket . io

This will install SocketIO to your node_modules directory so that now everything should be ready for us to push some updates! But before we do anything else let's run our server just to make sure everything works out alright. Type in the following command in your console:

node app . js

If the installation went fine you should see the following in your console:

App listening on port 3000

This means that our server is up and running. Just use CTRL+C to stop it. Now let's create an update! Go into your text editor of choice and type in something like this:

The Okie is very happy because @RyanSinger is online!

Now save your file as my_status.html inside the project directory you created earlier (if you followed my installation steps, go to "Okie" folder inside the "2016-08-20-okieio" directory). Make sure it has public access so that anyone can view it! We're done with our server for now so let's stop the node app again by pressing CTRL+C in the console. Now we need to create another file inside our project directory, this time it should be named server_client.js and it will look like this:

(Note that you can find a copy of server_client.js inside the "server" folder.)


We are social