Master the art of local commerce

Tips, tutorials and data to help you make the most of Ordrx’s platform

Ordr.in 101: API Overview

Posted by David
 

[Part of Sam's series on how to use the Ordr.in API]

The Ordr.in APIs are broken up into 3 modules - I’m going to chat a little bit about each one and what you use them for:

 

Restaurant API

The restaurant API is where the bulk of the work takes place for most basic apps. It allows you to get the relevant data about restaurants on the Ordr.in network.

It has four endpoints:

  • Delivery list - Find all restaurants delivering to a given address

  • Restaurant details - Access all of a specific restaurant’s data(most importantly, the menu)

  • Delivery check - Verify that a restaurant delivers to a given address, at a given time.

  • Fee - Calculates all necessary fees(like delivery/convenience charges)


User API

The user API allows you to:

  • Create users

  • Save/delete/modify address information

  • Save/delete/modify credit card and billing information

The only thing this does that you can’t do on your own is save credit cards securely - if you want to have saved cards, you’ll need to use the user API. If you don’t care about that - you can decide whether or not you want to store a lot of this information yourself or whether you want to store it via the API. Developers typically use this API to proxy the storage of user data, allowing them to store it with us behind the scenes. It may make your life easier if you plan on doing more complicated things with the API, but lets focus on throwing something basic together for your hackathon project.


Order API

This is where the magic happens! Sure, restaurant and user data is nice, but what you really want to do is order some damn food! This is the simplest of the three in principle, but requires the most amount of data(stuff like credit card info, name, email, phone number, delivery address, billing address, not to mention the actual order! jeez!). There is really only one endpoint in the order API but it can be called in two ways: guest order and user order.

Guest order is what most basic apps use because it usually takes one "line" of code after gathering the data. All you need to do is send a POST request (or make an API wrapper call) to guest order with the relevant info, and you're done! That will place an actual food order(or a test order if you are using the test API).

User order is really helpful as well because it makes things less janky if you already have your user data saved. It requires the same kind of authentication (not OAuth, don’t worry :) that the User API has.

And that's all there is to it! Please check out the other 101 posts:

API Overview

API Walkthrough

Dealing With The Menu

Test vs Production

 

How the Hell Do I Use the Ordr.in API?

Posted by David
 

[Sam, one of our Dev Evangelists, wrote this massive blog post on the basics of using the Ordr.in API. We've broken it up into a few chapters and hope to refine this as we get more questions via email and at hackathons. It's essentially the answers to the FAQs we get. So if you've got questions, send them our way!]

So this past Summer, I was a hackNY fellow and an Ordr.intern (yeah I like stupid cheesy puns). It was definitely the greatest Summer of my life. I will get around to talking about how amazing hackNY is some other time though. At Ordr.in, I had the opportunity to hack on some really cool open source stuff like this and this, as well as some awesome, less flashy, "evil" proprietary stuff that "helped the business grow." Now as an Ordr.in Developer Evangelist, I’m repping this bad ass API at hackathons. So to make my life easier in the inevitably sleepless upcoming weekends, I will lay down some basic knowledge here of how to get things working!

I’m going to break this down into bite size bits so you can just read what you need to read.

 

API Overview

API Walkthrough

Dealing With The Menu

Test vs Production

 

As always, it is great to see what people are building, so please tweet @sagnewshreds and @ordrin to let us know what amazing things you all wind up making! Anyone who builds something with the API will receive a kick ass exclusive Ordrin t-shirt (not the standard one with the fortune cookie logo, which is also a kick ass shirt)!


Shoot me a tweet or an email if you need any more help!

 

Unhackathon + Ordr.in = Awesomeness

Posted by David
 

Not long ago, Ordr.in sponsored Unhackathon, our first college hackathon of the new season, and it was a blast! The organizers did a great job of making an event that focused on being inclusive and beginner friendly. It was refreshing for the focus to not be on huge prizes and overemphasized competition as is common these days. Between the awesome food, an amazing venue at AlleyNYC and the creative side events like participants being able to paint their own t shirts - Unhackathon was a huge success. It was also a great weekend for Ordr.in, with 11 hacks built on our API!

 

It was a small event and Ordr.in was the only API sponsor. That meant I had to hustle like never before to help hackers out, but it was worth having all eyes on us when it came to people thinking of hack ideas! There were two winners in each prize category and both of the prizes for “most entertaining hack” went to teams who used the Ordr.in API. Here are some of the coolest things that were built using Ordr.in over the weekend:

 

Sweet Depression (Most entertaining hack award)

This is one of the coolest hacks I’ve seen in a while! The basic idea is that you give it your information (address, credit card, email, twitter handle, etc) and it will periodically perform sentiment analysis on your tweets. If your tweets are sad over time, it will use the Ordr.in API to order desserts for you. I am close friends with the members of this team, and know that they are some bad ass hackers! I’ve been looking forward to what they would do with the API, and they certainly did not disappoint.

 

RapEats (Most entertaining hack award)

Here is another hilariously awesome project. Made by two Rutgers hackers, including the new director of HackRU. This one is a chrome extension that replaces your new tab window. With RapEats, whenever you open a new tab, food is suggested to you based on rap lyrics. Using the Rap Genius API, as well as some hilarious pictures from a Tumblr page called Pictures of Rappers Eating, lyrics containing food items are displayed along with a box for you to order the food that was mentioned in the song. Many laughs were had with this at Unhackathon!

 

Voice Ordr

This allows you to order food via voice recognition! You just say what food you want, and it will figure out what you said and place an order for you. I think they only made it work in the terminal, given the time restrictions, but I am looking forward to when this gets polished and thrown into production!

 

Spoons and Tunes

What struck me about this one was that it made Spotify playlists for upcoming music events, and ordered you food based on the genre of the performer to get you in the mood for a concert. They used 3 different APIs in this one, and API mashups are always cool for hackathons!

 

Ordrin Filesystem

This hack is seriously kick ass! Built by two Rutgers hackers who are also hackNY fellows, OrdrinFS creates a unix filesystem using data from the Ordr.in API. These two always tear it up at hackathons, so I was excited when they told me they wanted to hack on the API. Each restaurant’s menu manifests itself as files and directories, and you can place orders by writing to an “ordr.in” file! The results of your order are then written to a file called “ordr.out.” This is pure genius!

 

KeepTrolling

This one was a solo hack, and it is pretty crazy. Written entirely in C, it is a trojan that you can control via an IRC chatroom. The idea is that if your friend leaves a computer unattended, you will run this code, and whatever people say to the chatbot will happen to your friend’s computer. There were about a dozen different things you can do, including opening the CD drive(if there is one), but you could also have food delivered to your friend without them realizing what happened. It is apparent that a lot of fun was had in the making of this hack.


Unhackathon was awesome - I had a great time helping hackers out and meeting a ton of new people! We are all super excited to be at this upcoming HackRU! I can’t wait to see how people continue to come up with crazy awesome use cases for the Ordr.in API.

 

-- Sam Agnew - Dev Evangelist - @SagnewShreds

 

One word about CalHacks: Holy Cow that was Cool

Posted by David
 

Last weekend Jason Teplitz, former Ordr.in intern & genius evangelist represented Ordr.in at Cal Hacks. Huge shout out to the organizers! There were over 1,500 hackers there, and the event was amazing. Smoooooth runnings. Here are some of the coolest hacks built on Ordr.in:

  • Spazz4fudz, the winner of best use of the Ordr.in API, orders food Twitch Plays Pokemon style. Fight against your friends, by mashing on the arrow keys to force the penguin towards the restaurant that you like. Once the penguin hits a restaurant, you can order food from it with the Ordr.in widget. Check out the video. 

  • SmartBox was a physical box that could detect your mood and respond to requests. Among those requests: “Order me food” would launch the Ordr.in widget.
  • KnapSack is an iOS app that remembers your budget and location so that you can order a randomized meal within your price range at the press of a button. Gold star to Shreyas Kalyan who, while working on Knapsack, upgraded the ordr.in swift library to be compatible with the newest version of Xcode.
  • OrderBot allows you to text a number with your food request and it would order it for you. Natural language processing, SMS, and food. Yum!
  • feedMe saves all your information and picks a random restaurant near you. At the press of a button you can either order a randomized meal from that restaurant, or order an uber to take you there. For most of the team this was their first webapp. We were pumped that they chose to learn webdev on the Ordr.in API.

Nearly half of these hacks were built using the Ordr.in widget, which is now new and improved thanks to Polina.  Enjoy the cool pics, especially the LIGHTSABRES we gave out as prizes.  Can’t wait to see what people build with it at HackRU this weekend!

 

 

The new Ordr.in widget is powerful like a bionic unicorn

Posted by David
 

Seriously. A bionic unicorn with a rainbow tail. And we have our developer Polina Viro to thank.

unicorn.png

Our embeddable widgets adds a menu just like you'd add a youtube video - with a few lines of javascript and html. You can let your users to either search for a restaurant - either with or without a default address, or go directly to ordering from a restaurant specified by the ordr.in restaurant ID.

The new widget allows for selecting which restaurant to order from: you can now input your address and check out the list of all restaurants that potentially deliver to your location (as well as see which ones are open and closed at the given time). In addition, if you’re embedding the widget, you may choose to prefill the delivery address for your customer. In that case, you’re immediately taken to the restaurant select page (with an option to change the delivery address).

Second, there is now a single widget. Old-timers will remember how there were two widgets - one for mobile, and one for web views. Now there is a single, responsive widget in the place of the two - the mobile view being activated for widths under 810px, and the web view for anything wider than that.

Thanks, Polina!

 

 

We are soon retiring our developer t-shirts

Posted by David
 

Time for something new, but the message on the back is eternal. If were this cool with our first shirts imagine the second set. Woooeee! 

 

Come to CalHacks

Posted by David
 

We are psyched to sponsor CalHacks- our first west coast hackathon. If you are going look for Jason Teplitz, our dev evangelist, who will be working the event. He has stickers, t-shirts for teams working with our API and will give out very, very cool prizes for the best the and most fun Ordr.in hacks.

Before you crack your first redbull get familiar with the API on our Dev Portal and fire any questions to hackfood@ordr.in. 

We are not screwing around. Both winning teams will get one of a kind, never to be reprinted custom Ordr.in hoodies. And the grand prize winner will be Force FX Lightsabres.  

Node. It is your destiny.

Node. It is your destiny.

 

Life, Startups and Everything

Posted by David
 

We were thrilled to be interviewed by Matylda Czarnecka of New York Internet Week. The conversations covered many things, especially the life of a startup and the lives in a startup. 

Everything is harder than you expect it to be and everything is more awesome as well.
— Felix Sheng, CTO

Let us know what you think.