Skip to main content

Removal of slug on entry links

Log in to add to favourites

If you do rely on having slugs for entries in links then you can return them by specifying a linkDepth of 1. Alternatively if you are moving over to using nodes then you can use the full URI returned in the link.

Version 11

JSON
{
    "title": "Doctor Strange",
    "actors": {
        "sys": {
            "id": "015e3e82-8451-42ee-99eb-155445c5b2f8",
            "dataFormat": "entry",
            "slug": "benedict-cumberbatch"
        }
    },
    "entryTitle": "Doctor Strange",
    "sys": {
        "id": "71f73a9b-2a13-4d63-bcc1-e8ee5047b01c",
        "contentTypeId": "movie",
        "projectId": "movieDb",
        "language": "en-GB",
        "uri": "/api/delivery/projects/website/entries/71f73a9b-2a13-4d63-bcc1-e8ee5047b01c",
        "dataFormat": "entry",
        "metadata": {},
        "version": {
            "createdBy": "s.derrickson",
            "created": "2016-10-12T09:29:18.5144641+01:00",
            "modifiedBy": "b.cumberbatch",
            "modified": "2016-10-13T10:15:12.1973648+01:00",
            "publishedBy": "b.cumberbatch",
            "published": "2016-10-13T10:15:12.1973648+01:00",
            "versionNo": "2.0"
        }
    }
}

Version 12

JSON
{
    "title": "Doctor Strange",
    "actors": {
        "sys": {
            "dataFormat": "entry",
            "contentTypeId": "actor",
            "id": "015e3e82-8451-42ee-99eb-155445c5b2f8",
            "uri": "/actors/benedict-cumberbatch"
        }
    },
    "entryTitle": "Doctor Strange",
    "sys": {
        "id": "71f73a9b-2a13-4d63-bcc1-e8ee5047b01c",
        "contentTypeId": "movie",
        "projectId": "movieDb",
        "language": "en-GB",
        "uri": "/api/delivery/projects/website/entries/71f73a9b-2a13-4d63-bcc1-e8ee5047b01c",
        "dataFormat": "entry",
        "metadata": {},
        "version": {
            "createdBy": "s.derrickson",
            "created": "2016-10-12T09:29:18.5144641+01:00",
            "modifiedBy": "b.cumberbatch",
            "modified": "2016-10-13T10:15:12.1973648+01:00",
            "publishedBy": "b.cumberbatch",
            "published": "2016-10-13T10:15:12.1973648+01:00",
            "versionNo": "2.0"
        }
    }
}

Still need help?

If you still need help after reading this article, don't hesitate to reach out to the Contensis community on Slack or raise a support ticket to get help from our team.
New support request