Anchor to urlRedirectUpdateurl
urlRedirectUpdate
mutation
Requires access scope.
Updates a URL redirect.
Anchor to Arguments
Arguments
- •ID!required
The ID of the URL redirect to update.
- Anchor to urlRedirecturl•
Redirect UrlRedirect requiredInput! The input fields required to update the URL redirect.
Was this section helpful?
Anchor to UrlRedirectUpdatePayload returnsUrlRedirectUpdatePayload returns
- Anchor to urlRedirecturl•
Redirect Returns the updated URL redirect.
- Anchor to userErrorsuser•
Errors [UrlRedirect non-nullUser Error!]! The list of errors that occurred from executing the mutation.
Was this section helpful?
Mutation Reference
mutation urlRedirectUpdate($id: ID!, $urlRedirect: UrlRedirectInput!) {
urlRedirectUpdate(id: $id, urlRedirect: $urlRedirect) {
urlRedirect {
# UrlRedirect fields
}
userErrors {
field
message
}
}
}
Input
{
"id": "gid://shopify/<objectName>/10079785100",
"urlRedirect": {
"path": "<your-path>",
"target": "<your-target>"
}
}
{
"id": "gid://shopify/<objectName>/10079785100",
"urlRedirect": {
"path": "<your-path>",
"target": "<your-target>"
}
}
input UrlRedirectInput {
path: String
target: String
}