post
https://{yourinstance}.makaira.io/redirects/bulk
Create redirects in bulk
Creates multiple redirect rules in a single request.
Requires authentication.
Request
POST /redirects/bulk
Headers
| Header | Value |
|---|---|
Authorization | Bearer <token> |
Content-Type | application/json |
Request Body
An array of redirect objects:
| Field | Type | Required | Description |
|---|---|---|---|
source | string | Yes | Source path to redirect from. Must start with /. |
target | string | Yes | Target path to redirect to. Must start with /. |
code | integer | Yes | HTTP redirect status code (e.g. 301, 302). |
priority | integer | No | Priority for this redirect. |
Example Request
[
{
"source": "/old-page-1",
"target": "/new-page-1",
"code": 301
},
{
"source": "/old-page-2",
"target": "/new-page-2",
"code": 301
}
]Response
Response Body
| Field | Type | Description |
|---|---|---|
Success | boolean | true if all redirects were created successfully. |
Error | array | List of errors, if any. |
Example Response
{
"Success": true,
"Error": []
}
