Mozscape API call returning no json
-
Hi - I'm having issues getting started with the Mozscape API. I'm putting the following into my browser:
http://[member-ID]:[secret key]@lsapi.seomoz.com/linkscape/url-metrics/greatbritishchefs.com
According to the blog posts I'm reading I should get loads of json script returned but all I'm getting is {}
Does anybody have any pointers as to what I might be doing wrong?
Thanks
-
Looks like AoV and I posted at the same time. AoV is exactly right. We're both pretty much saying the same thing. Add a Cols parameter and you should be good to go.
Good luck!
-
Hi - I usually use the URL format shown here:
http://www.seomoz.org/api/keys
They have a "sample request" shown here, that you can use to get started. I know they recently stopped supporting the old API format, and it caused a bunch of the scripts I run to stop working. One of the tricky things about the new API format is the 'cols' parameter, where you specify the data that you want returned. They added this to restrict the amount of data that is returned. Before it returned a bunch of data, that maybe users were not really interested in - and so it used more of their server resources and bandwidth.
You can see details about how to use the 'cols' parameter for URL metrics here:
http://apiwiki.seomoz.org/url-metrics
You have to add up the bit values for the fields that you want to have returned. So for instance, if you want only the 'external links' data (32) and the 'mozrank' data (16384), you'd set the cols flag to be 16416 ... (32 + 16384).
Hope that helps ~
-
I just submitted a YOUmoz post on this topic. Hopefully it runs the gauntlet and is approved.
The Mozscape API used to provide everything if you did not provide a Cols parameter to the request. Now you need to send a Cols value with the summed up total of all the bit flags you want the request to return. You can find all of the URL Metrics bit flags and their values here.
Here's an example using your URL and these bit flags: Title (1), URL (4), External Links (32).
http://[member-ID]:[secret key]@lsapi.seomoz.com/linkscape/url-metrics/greatbritishchefs.com?Cols=37
The value 37 represents the bit flags you want to get back added together like so:
Title (1) + URL (4) + External Links (32) = 37
Hope this helps!
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Why is MOZ crawl is returning URLs with variable results showing Missing Meta Desc? Example: http://nw-naturals.net/?page_number_0=47
Can you help me dive down into my website guts to find out why the MOZ crawl is returning URLs with variable results? And saying this is missing a description when it's not really a page? Example: http://nw-naturals.net/?page_number_0=47. I've asked MOZ but it's a web development issue so they can't help me with it. Has anyone had an issue with this on their website? Thank you!
Moz Pro | | lewisdesign0 -
API for On Page tool
I'm looking for a tool similar to On Page Grader (Moz) or Focus Keyword (Yoast) with API. We are building out or internal CRM system. Even though none of these tools can replace manual on page analysis, it will be used as a metric and to catch human mistakes.
Moz Pro | | OscarSE0 -
Rank tracking in Excel via MOZ API?
Hi there, i hope someone knows the solution to this problem. I created/ copied the "advanced Excel Keyword Analysis Report" that Dan Peskin was kind enough to share, you can find it here: http://moz.com/blog/how-to-build-an-advanced-keyword-analysis-report-in-excel. Now i m looking for a solution to rank my Keywords by using an API, preferably the MOZ API. My keywords are alligned in a column "Keword List", which will be regularly updated. Next to this column i would like to have a column with the corresponding rank. Is there a automatic solution, or do i have to do it manually?
Moz Pro | | Juri.Rabiner0 -
I keep getting Authentication Failed on the API
I have the credentials in the URL correctly but it will continue to fail authentication. I will not post them obviously but is there a problem with the API currently? I tried creating new credentials Also I have used this before so I am sure it is not a problem with the credentials. I somehow managed to get Chrome to show the data. Firefox will not and the code i have written also return authentication failed. This is a bug on your end. Please fix it ASAP.
Moz Pro | | ColumK0 -
Adding canonical still returns duplicate pages
According to SEOmoz, several of my campaigns show that I have duplicate pages (SEOmoz Errors). Upon reading more about how to resolve the issue, I followed SEOmoz's suggestion to add rel='canonical' <links>to each page. After the next SEOmoz crawl, the number of SEOmoz Errors related to duplicate pages remained the same and the number of SEOmoz notices shot up indicating that it recognized that I added rel='canonical'.</links> I'm still puzzled as to why the SEOmoz errors did not go down with respect to duplicate page errors after I added rel='canonical', especially since SEOmoz noticed that I added them. Can anyone explain this to me? Thanks,
Moz Pro | | MOZ2
Scott.0 -
Why do you call it a Campaign?
I'm trying out PRO and have a simple question. Why do you call the main organizational unit in this tool a "Campaign"? "Campaign" makes me think of advertising or direct mail - run over a specific period of time to a specific audience. But, "Campaign" in SEOmoz PRO seems to mean a collection of keywords plus a domain. Is the idea that I'm investing time an money in this collection of keywords in some sort of a structured campaign (using SEO techniques) and then using PRO to track performance against a baseline? By the way, the tool seems great and I love the useful data it provides. I guess I'm really trying to understand the SEO mindset the underpins the design of PRO. Thanks for any help!
Moz Pro | | dbmmark0 -
Website is not being indexed in Mozscape
Hi, We launched a website Mid-March. Strangely it's not yet being indexed by the Mozscape crawler (therefore I can't use tools like Open Site Explorer). Open Site Explorer keeps telling me: "No Data Availible for this URL". I don't think it's a crawl error of some sort. Google Webmaster tools tells me everything is fine (no crawl errors). Search Engine indexing is also fine. Any thoughts on this? Thanks.
Moz Pro | | Vendic0 -
About Links API
I'ma Japanese, So, I'm sorry in poor English.
Moz Pro | | flaminGoGo
Question about the API.
Will be returned as unauthorized api 'links' to the following request. http://lsapi.seomoz.com/linkscape/links/domain/blog?Scope=page_to_page&Sort=domain_authority&AccessID=xxx&Expires=xxx&Signature=xxx Is it OK in the request parameters?0