SEO Culture
Publisher SEO
Business & Reporting
Botify News & Products
SEO Foundations
SEO News & Events
Future of SEO
E-Commerce SEO
Enterprise SEO
Content SEO
Technical SEO

Back to blog

SEO Foundations

An SEO's Guide To The Botify API

 min read
November 21, 2019
Andreas Voniatis
Growth Consultant

The purpose of the Botify API is to integrate Botify with third-party applications, thus enabling SEOs and stakeholders to use any data available in the Botify interface or via the Botify Chrome Extension with their unique business solutions. Take a look at how Botify customer Andreas Voniatis learned how to interpret and utilize the Botify API successfully.This article was contributed by Andreas Voniatis, Marketing Scientist at Artios, growth hacking scientists using AI to boost your profits.

Why I'm sharing our learnings about the Botify API

While the Botify API guide is straight-forward and helpful, my team faced some challenges interpreting it in the right way. As a result, our immediate thought was that some SEOs might not use the API, not because they didn't want to but because it's an investment in time (And who has time?).The API guide quite correctly assumes that its users are tech savvy and use APIs all the time. However, while technically skilled at website audits, some SEOs might find working with APIs rather intimidating. This could be due to stress from managing many responsibilities, being stretched for time, or the growing pains of transitioning to a new software.To save time, we have put together a companion guide for SEOs to get the best out of the Botify API, including the typical use cases that an enterprise-level SEO or data scientist is likely to encounter.To note, the code below is written in R (Sorry, Python users! However, R code is quite readable and similar to Python and should be fairly easy to translate). Fear not. If you can't code, you really only have to edit two lines of code (and then the rest is done!).

Retrieving your projects

To get your data, you need to see and know which projects you have. Here is the R code to do that:Once done, your output of the first few columns should look like this:

Retrieving your audits

In Botify's API language, an audit is an "analysis." Next up is code to list your analysis:Looking at the dimensions of the output:We can see that there are 2,201 individual columns and over 81 audits that have been run. Naturally, we shall not list the columns here! To note, you will only need some of these fields (maybe 100-600), whereas the others will include metadata (like project names, owners, email addresses, etc.) that aren't directly linked to your SEO business data.To give you an idea of the output (i.e. the all_analyses object), see below:

Extracting your audit data

You're now in a position to get all of your audit data from your analysis. Here's how:Lines 1-30 (of 264) from the bql_fields.csv fileThis may take a few minutes to run depending on the size of your site. A 1 million page site, for example, will take about 5-10 minutes maximum.Let's inspect the output:As you can see from the first 6 rows, there are 209 columns starting with "byte_size."

In summary

You now have the code in R, and with only two lines to edit, you can interact with the Botify API that allows you to:

  • Find which projects you have
  • Find the audits (a.k.a. analyses)
  • Extract all the data you need from each analysis in a tabular format

Simply copy the code above and, libraries permitting, you're good to go.Now you're ready to do some SEO data science!

Want to learn more? Connect with our team for a Botify demo!
Get in touch
Related articles
No items to show
Join our newsletter
SEO moves fast. Stay up-to-date with a monthly digest of the industry's best educational content, news and hot takes.