Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Updating EntityUrl output object in urlResolvers query #6812

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions src/guides/v2.3/graphql/queries/url-resolver.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ The following query returns information about the URL containing `joust-duffle-b
urlResolver(url: "joust-duffle-bag.html") {
id
relative_url
redirectCode
type
}
}
Expand All @@ -39,6 +40,7 @@ The following query returns information about the URL containing `joust-duffle-b
"urlResolver": {
"id": 1,
"relative_url": "catalog/product/view/id/1",
"redirectCode": 0,
"type": "PRODUCT"
}
}
Expand All @@ -59,11 +61,11 @@ The `EntityUrl` output object contains the `id`, `relative_url`, and `type` attr

Attribute | Data Type | Description
--- | --- | ---
`canonical_url` | String | Deprecated. Use `relative_url` instead.
`id` | Int | The ID assigned to the object associated with the specified `url`. This could be a product ID, category ID, or page ID.
`relative_url` | String | The internal relative URL. If the specified `url` is a redirect, the query returns the redirected URL, not the original.
`type` | UrlRewriteEntityTypeEnum | The value of `UrlRewriteEntityTypeEnum` is one of PRODUCT, CATEGORY, or CMS_PAGE.
`url` | String | The URL to resolve. Magento stores product and category URLs with the `.html` extension. CMS URLs do not contain the extension.
`canonical_url` | String | Deprecated. Use `relative_url` instead
`id` | Int | The ID assigned to the object associated with the specified `url`. This could be a product ID, category ID, or page ID
`redirectCode` | Int | Contains 0 when there is no redirect error. A value of 301 indicates the URL of the requested resource has been changed permanently, while a value of 302 indicates a temporary redirect
`relative_url` | String | The internal relative URL. If the specified `url` is a redirect, the query returns the redirected URL, not the original
`type` | UrlRewriteEntityTypeEnum | The value of `UrlRewriteEntityTypeEnum` is one of PRODUCT, CATEGORY, or CMS_PAGE

## Related topics

Expand Down