API obsession



I have been obsessed with APIs lately. Obsessed. Part of this stems from the interest in coding, of course, but part of it has come from a new focus on automating a lot of manual processes out of existence. I think I first really started messing around with them via crypto — of course — through the need to maintain price tracking sheets for my spec mining projects. I wanted to be able to keep track of the amount of coins that we were mining, the current price of said assets, and use that to calculate earnings and so forth. When I started tracking, I would manually get the prices from the exchange, paste them into a Google Drive doc, then copy my totals from one tab into a running monthly sheet. It quickly became tiresome, and when I found an add-on that someone had created to do lookups via CoinMarketCap (CMC), I became very interested in figuring out how it was done.

Eventually, I got interested in projects that weren’t available via this CMC interface, and had to start rolling my own. I was able to write Google scripts that could call the APIs of various exchanges and mining pools, to give me exchange totals, prices, and mining payouts. I’ve added them to a hodge-podge collections of scripts that I maintain in a sheet, so I can keep track of the entire venture. I use them to plan trades and track positions afterward. Of course Google Sheets has its limitations, and most of my work is in Python, but the basic premise is the same. Wrap an API request in a function wrapper, do something interesting with the result.

A lot of the interest also comes from my interest in automation. I’ve read the stories about people who have automated their jobs using Python, for example, and one of the fun things about APIs is that not only can you get information out of them, but you can send requests to them and make them do things for you. To stick with fintech for a bit longer, trade execution platforms are a perfect example of this. Being able to send orders to a trading platform through an API has enabled the high-frequency trading and bots to take over the markets. But my main interest is a bit closer to home, or work, to be more precise.

At my day job, we use several different systems to maintain our operation. The crux of it is a professional services automation (PSA) ticketing system and a remote monitoring and management (RMM) system. The two vendors that we use are integrated petty well. There are several major players in the space, and most of them plug together pretty well. The main issue is that the PSA requires a lot of manual setup and steps to do basic things like setting up new clients, configuring contracts, maintaining inventory. All which require multiple steps through their rather clunky UI. It’s a pain. Even something as simple as closing a ticket requires 4-5 mouse clicks.

Using the PSA’s API, I’ve begun to draft a collection of function that will allow me to close a ticket using a simple close_ticket(ticketID) call. I’ve developed more complicated functions that will create contracts, add products to those contracts and link assets from the RMM to those contracts. Right now I’m focused on standardizing operations across our clients, but there’s further opportunity to standardize operations between all of our franchise partners.

But perhaps the most critical opportunity that I’m focusing on within my day job is eliminating failures caused by human error.

Hotel Alexa

I’m staying in a hotel tonight. It’s not something that I usually do but there’s been a couple of family events that have brought me and the crew out of town. I woke up this morning before dawn and found myself staring at this bright green light a few inches away from my face. It’s probably just the thermostat or something, but it got me thinking: how long before Hilton and the other big hotel chains start putting voice assistants in rooms?ย 

I probably wouldn’t be thinking this if the front desk had picked up the phone any of the dozen times I tried to call them last night, but it seems inevitable that there’s some company out there working on a bot for one of these chains: “Alexa, I need more towels.” “Alexa, how do I connect to wifi?” “Alexa, what channel is Disney channel?” “Alexa, have room service bring me dinner.”

Listening

Seems inevitable. I’m sure it will be a while before people are willing to accept these things in their rooms. Some, like myself, aren’t comfortable having these things in my house, let alone rooms where they are sleeping or doing other more intimate activities. I assume that the hotels could hand them out at the front desk as an option: “Would you like a virtual assistant with your room, sir?” And then I’m sure it’d be a matter of time before they’d become standard deployments the way wifi repeater seem to be everywhere.ย 

Update: It seems I’m a bit late to the party. Amazon released their Alexa for Hospitality in June of 2018:

Guests will be able to do things like order room service, request a housekeeping visit, or adjust room controls (thermostat, blinds, lights, etc.) using an Echo in their room. They can also ask location-specific questions such as what time the hotel pool closes or where the fitness center is.

Some upscale Vegas hotel apparently pioneered Alexas in their rooms back in December 2016, and in October of last year, Marriot announced plans to run a trial in Charlotte hotels. One thing that we didn’t anticipate when we were writing this was the response of hotel staff, who saw these devices as a threat to job security as far back as September. It was apparently part of a list of concerns whenย  Marriott employees went on strike last fall.ย 

https://imgs.xkcd.com/comics/listening.png