Import redirects
POST
/ admin/ v1/ stores/ {store_id}/ redirects/ import- content:write
- Idempotency-Key supported
Import redirects from CSV (Redirect from,Redirect to, the format Shopify exports; ; separators work too). Valid lines are created together; lines whose path already redirects are skipped; the rest are reported by line.
Path parameters
store_idstringrequiredThe store's ID, like
store_01k8qs5s…. Apps get it with the install, in the OAuth redirect and the token response.
Headers
Idempotency-KeystringSend the same key to retry safely: the first answer is replayed for 24 hours.
shop-api-versionYYYY-MMThe version to answer in. Without it, your app’s pinned version, else the newest.
Body
csvstringrequired
Returns
200 What was created, skipped and left out.
Errors
- 403
forbiddenMissing permission. - 409The import would pass 100,000 redirects (
redirect_limit). - 422
validation_failedNot CSV, empty, or more than 20,000 lines.