Search engines crawl the web continuously, 24/7 and 365 days per year. So if you want to catch and remedy issues and unexpected changes before they hurt you, you need your tooling to do the same. That’s why today we’re introducing the ContentKing API.
ContentKing does a great job at assessing which pages to crawl when. But the brand new API takes that even further—integrating our API into your publishing workflow triggers priority auditing of the page you’re working on for on-the-fly change tracking. Make a change to your page and instantly see the results in ContentKing.
Yes, this is an absolute game changer and it’s features like this that make us so excited to be leading the field of SEO auditing into a new era!
Integration is relatively simple, but you’re going to want to involve someone with a developer background. Make sure to send them the link to this article to help them on their way. And if they run into trouble, our support team is more than happy to assist!
First you’ll need to get your ContentKing account’s API token. You’ll find it in the Account section, under the Team Profile tab.
The overall idea here is that every time you make a change through your CMS, such as adding, deleting, or changing a page, you need your website to call the ContentKing API. You do this using a POST-request to the following endpoint:
Read on to learn exactly what payload to send.
When making a request you need to send along the following request headers:
Note: you need to provide the string “token” followed by a space and your actual API token.
Then, as the body of the request, you need to send a JSON object containing the full URL you want ContentKing to check:
Note: don’t forget to include the domain name and protocol (
https) in your request.
After sending the call, the ContentKing API will reply with one of the following responses:
“status” : “ok”
This response means that the request was successfully processed and that the page will be checked immediately.
“message”: “Authentication token must be passed in Authorization HTTP header.”,
This response means that the request was received, but that it’s lacking an authorization token and can therefore not be processed. Make sure to correctly set the Authorization header.
“message”: “Authentication token is expired or invalid.”,
If you get this response it means that the request could not be processed because the supplied API token is invalid or expired.
“message”: “Authorization HTTP header must conform to format described in docs.”,
This response means that the request was received, but that the authorization wasn’t formatted correctly. Make sure to correctly set the Authorization header.
“message”: “Invalid url format provided.”,
If you receive this response it means that you sent an incorrectly formatted URL. Double-check that you sent a fully qualified URL, including the domain name and protocol.
“message”: “Website isn’t registered in CK account.”,
When you get this response, the website you’re requesting for doesn’t exist in the ContentKing account belonging to the API token.
In case you or your developer need any help with integrating the API don’t hesitate to reach out. We’re always happy to help!