Redirect Object

Field Guide

Name Type Example Notes
id String 5214c83d45667acd25394b54 Unique identifier
siteId String 5214c83d45667acd25394b53 The id of the Site that this Redirect is associated with
urlMapping String /old/article/1234 The path to redirect from
type String article The type of resource this Redirect points to. This can take one of four values:
  • article - A Docs article belonging to the account whose site is specified by siteId.
  • category - A Docs category belonging to the account whose site is specified by siteId.
  • collection - A Docs collection belonging to the account whose site is specified by siteId.
  • custom - Used for all other cases; for example for a redirect to an external URL.
documentId String 7214c83d45667acd25394b53 If the Redirect type is either an article, category or collection, then this field is the unique identifier of that resource. For custom redirects, it is blank.
anchor String section-1 If the Redirect type is either an article, category or collection, then this field is the HTML anchor point from the redirect URL (if there is one). For custom redirects, it is blank.
redirect String https://docs.helpscout.net/article/69-respond-to-conversations The fully qualified URL to redirect to.
createdBy Integer 73423 The Help Scout id of the user who created this Redirect.
updatedBy Integer 73423 The Help Scout id of the user who last updated this Redirect.
createdAt DateTime "2013-08-21T19:34:13Z" The UTC date/time that the Redirect was created.
updatedAt DateTime "2013-08-21T19:34:13Z" The UTC date/time that the Redirect was last updated.

Example

{
  "redirect": {
    "id": "573df74195ac0e2ad08ab695",
    "siteId": "52444ccf3e3e9bd67a3dc68c",
    "urlMapping": "/previous/url/1234",
    "documentId": "525217bae4b0cb13e565bb9d",
    "type": "article",
    "redirect": "https://docs.helpscout.net/article/488-transfer-account",
    "createdBy": 4577,
    "modifiedBy": 4577,
    "createdAt": "2016-05-19T17:26:25Z",
    "modifiedAt": "2016-05-19T17:26:25Z"
  }
}