At import.io, we’re always trying to make getting and using data from the web easier and less painful. It’s what led us to create Magic – our famous one click to data feature. But, it’s been awhile since we’ve done something specifically for our developer community. Well devs, the wait is over. Welcome to the brand new API docs!
APIs with Swagger
These new docs aren’t just easy on the eyes, they’re also far more interactive. We’ve built them using Swagger, which allows you to play with the APIs and generate your own client libraries. All you need is your API key (which you get by putting in your import password at the top of the page) and you can get real, useable snippets that you can integrate straight away.
Magic Methods
The most exciting thing about our new API docs? We’ve given you access to the Magic API!
Using this API you can put in a URL directly into the API docs and see all three of the tables that Magic returns. When you run Magic across a site, our algorithms are looking for the lists with the most data in them. In the UI we service the “best” one, but in our API docs we show you the top three giving you greater flexibility over the data you can pull back with Magic.
We’ve also given you a regionText field where you can specify a word or phrase on the page that you want Magic to look for when it’s searching for tables to make the extraction laser focused.
Beta Features
With this Magic API release we’re also giving you early access to two very exciting beta features.
Changing js from false (default) to true will allow you to process sites through Magic that require JavaScript to render their data. Our new beta feature renders the site with Javascript on making it easier for Magic to process.
If the site you’re trying to extract data from has the double whammy of js AND infinite scroll, you can use our second beta feature infiniteScrollPages. It works by re-rendering your site as HTML and then manually scrolling down or clicking “load more” for as many pages as you request in the box. Note that infiniteScrollPages needs javascript turned on too!
Please note that both of these features are in beta mode – you can tell us about any wins or issues through support.import.io!
Share the love
We’ve created these new API docs and given you access to the Magic API because we want to see what cool things you guys could do with it. If you’ve build an awesome project, solved a data problem, or have feedback on the new docs; we want to hear about it. Tell us about it in the comments, share it with @importio on Twitter or send it to us the old fashioned way on hello@import.io.