V2 Final Redirect (Legacy)

Looking for documentation for the current iteration of the Moz API? Access it here!

What's Covered?

In this guide you’ll learn more about making API calls to the Final Redirect endpoint for the Moz API V2.

This documentation specifies information for Moz API V2. V1 of the Moz API does not include a Final Redirect endpoint.

Have you heard? All the Moz API endpoints are now available in one unified API instance. To learn more and get started, check out the all-new documentation here.

What is this endpoint for?

Use this endpoint to see the final redirect target of a page after following known redirects in the index. For example, if we request the final redirect for seooutdoorsrank.com/blog, the API will return outdoorsrank.com/blog as the final redirect target. This data can be helpful for tasks like technical audits. If you have migrated your domain or a set of pages and need to check that the redirects were implemented correctly, this endpoint can help with that.

Quick Links
Please note: The documentation found here is for the legacy Moz API V2 only. Our updated documentation for the current version of the Moz API can be found here

Getting Started

Before making calls to the Final Redirect endpoint, be sure you are set up with an API token within your Moz Account.

For information regarding authentication, please see our Overview & Authentication guide.

All requests and responses are structured in JSON.

Endpoint Location

When requesting final redirect data from Links V2, be sure to use the following endpoint.

          
https://lsapi.seooutdoorsrank.com/v2/final_redirect
        

Request Syntax

          
{
    "page": "string"
}
        

Example JSON Request

          
{
    "page": "seooutdoorsrank.com/blog"
}
        

Request Parameters

"page" - A page to find the final target for.

  • Type: string
  • Required: yes

Response Syntax

          
{
    "page": "string"
}
        

Example JSON Response

          
{
   "page": "outdoorsrank.com/blog"
}
        

Response Elements

"page" - The final target of a page after following known redirects, or an empty string if no redirects are known.

  • Type: string

Errors

See the Common Errors section for errors that are common to all endpoints.

Example HTTP Request

          
POST /v2/final_redirect
Host: lsapi.seooutdoorsrank.com
Content-Length: [length of request payload in bytes]
User-Agent: [user agent string]
Authorization: Basic [credentials]
{
    "page": "seooutdoorsrank.com/blog"
}
        

Example cURL Request

          
curl -d '{"page": "seomoz.org/blog"}' -X POST https://lsapi.seooutdoorsrank.com/v2/final_redirect -u 'access_id:secret_key'
        

Example Python Request

          
import requests
auth = (access_id, secret_key)<
url = "https://lsapi.seooutdoorsrank.com/v2/final_redirect"
data = """{
"page": "seomoz.org/blog",
    }"""
request = requests.post(url, data=data, auth=auth)
        

Related Articles


Woo! 🎉
Thanks for the feedback.

Got it.
Thanks for the feedback.