Redirect.li API
Access the Redirect.li service through the API.
HTTP API
Get HTTP headers
Get HTTP response header information for a URL
Query Parameters
These parameters can be supplied as a GET parameter.
URL to get information for
200 Success
This JSON object will be returned on a successful query.
The URL address that was requested. Some parts may be missing.
The URL protocol
The URL host domain
The URL path
The URL parameters
The full URL
HTTP status code, or error
HTTP status code message
HTTP status description
Total number of milliseconds for the whole request
Each request returns a step `object`. Multiple steps may be returned if a URL redirects.
The URL address that was requested. Some parts may be missing
The URL protocol
The URL host domain
The URL path
The URL parameters
The full URL
HTTP status code, or error
HTTP status code message
HTTP status description
IP address for the requested server
HTTP protocol version
Total time (milliseconds) for this step
Timing details for this step
All the response headers for this step
Header name
Header value
Alternative representation for value. For example, 3600 seconds = 1 hour
Header description
List of problems associated with this header
Identifier for the problem
Text description of the problem
Header type, otherwise `string`
URLs for more information about this header
Items
Details
List of problems
Identifier for the problem
Text description of the problem
Example
HTTP/1.1 200 OK
{
"url": "https://apple.com",
"status": 301,
"statusMessage": "moved permanently",
"statusDescription": "This and all future requests should be directed to the given URI",
"httpVersion": "1.1",
"timeTotal": 569,
"timeStages": {
"wait": 0.8,
"dns": 2.5,
"tcp": 1.1,
"firstByte": 1.1,
"download": 1.1,
"total": 569
},
"intent": "URL is being redirected to https://www.apple.com/",
"headers": [
{
"name": "server",
"value": "Apache",
"description": "A name for the server",
"details": {}
}
]
}
Decode HTTP headers
Get HTTP response header information for some POSTed headers. Note that some of the response contains empty values where it is not relevant.
JSON Body
These parameters can be supplied as a JSON encoded body.
Array of HTTP header values
Query Example
curl --header "Content-Type: application/json" --request POST --data '{"headers":["accept-ch: value"]}' https://api.redirect.li/v1/http/
200 Success
This JSON object will be returned on a successful query.
The URL address that was requested. Some parts may be missing.
The URL protocol
The URL host domain
The URL path
The URL parameters
The full URL
HTTP status code, or error
HTTP status code message
HTTP status description
Total number of milliseconds for the whole request
Each request returns a step `object`. Multiple steps may be returned if a URL redirects.
The URL address that was requested. Some parts may be missing
The URL protocol
The URL host domain
The URL path
The URL parameters
The full URL
HTTP status code, or error
HTTP status code message
HTTP status description
IP address for the requested server
HTTP protocol version
Total time (milliseconds) for this step
Timing details for this step
All the response headers for this step
Header name
Header value
Alternative representation for value. For example, 3600 seconds = 1 hour
Header description
List of problems associated with this header
Identifier for the problem
Text description of the problem
Header type, otherwise `string`
URLs for more information about this header
Items
Details
List of problems
Identifier for the problem
Text description of the problem
Example
HTTP/1.1 200 OK
{
"url": "https://apple.com",
"status": 301,
"statusMessage": "moved permanently",
"statusDescription": "This and all future requests should be directed to the given URI",
"httpVersion": "1.1",
"timeTotal": 569,
"timeStages": {
"wait": 0.8,
"dns": 2.5,
"tcp": 1.1,
"firstByte": 1.1,
"download": 1.1,
"total": 569
},
"intent": "URL is being redirected to https://www.apple.com/",
"headers": [
{
"name": "server",
"value": "Apache",
"description": "A name for the server",
"details": {}
}
]
}