short url id
1639562002248499321
GET /v1/link/{id} HTTP/1.1
Host: api.redirhub.com
Authorization: YOUR_API_KEY
Accept: */*
success
{
"id": "72288a61-034e-4596-80c9-88751cf0a937",
"host": "www.example.com",
"url": "www.example.com",
"alias": "aBD",
"https": true,
"destination": "https://www.google.com",
"destinations": "[]",
"type": "301",
"status": "active",
"forward_query": false,
"created_at": "2023-11-15T15:09:14.000000Z",
"updated_at": "2023-11-15T15:09:14.000000Z"
}
Get all short urls
GET /v1/link HTTP/1.1
Host: api.redirhub.com
Authorization: YOUR_API_KEY
Accept: */*
success
{
"data": [
{
"id": "72288a61-034e-4596-80c9-88751cf0a937",
"host": "www.example.com",
"url": "www.example.com",
"alias": "aBD",
"https": true,
"destination": "https://www.google.com",
"destinations": "[]",
"type": "301",
"status": "active",
"forward_query": false,
"created_at": "2023-11-15T15:09:14.000000Z",
"updated_at": "2023-11-15T15:09:14.000000Z"
}
]
}
Hostname
url.com
Slug
123
Destination URL
https://www.google.com
Type
301
whether forwarding query params to destination
false
POST /v1/link HTTP/1.1
Host: api.redirhub.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 106
{
"host": "url.com",
"alias": "123",
"destination": "https://www.google.com",
"type": "301",
"forward_query": false
}
success
{
"data": null
}
short url id
1639562002248499321
Hostname
url.com
Slug
123
Destination URL
https://www.google.com
Type
301
whether forwarding query params to destination
false
PUT /v1/link/{id} HTTP/1.1
Host: api.redirhub.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 106
{
"host": "url.com",
"alias": "123",
"destination": "https://www.google.com",
"type": "301",
"forward_query": false
}
success
{
"data": null
}