Contentful logo

Contentful Community

Republished entry not appearing in CDN

#1

We have a scenario where an editor moved an Entry from Published to Draft - then made some changes to the field values - and republished .

But now the Entry’s field content is not available at the cdn endpoint - fields just shows as an empty object -

In at the preview endpoint all the field content is available.

It seems the item’s field content was removed from the CDN and not restored when it was republished - is there a way to fix this?

0 Likes

#2

Hi Adam,

That surely shouldn’t be happening if you’re using our Delivery API properly and it might be an issue of how exactly you’re integrating Contentful into your application.

That being the case, could tell us what API endpoints you’re reaching (omitting all credentials, of course) or the actual code used?

0 Likes

#3

Hi Gabriel - thanks for your response and looking at this

Here is the query (without the access token, of course)

the response from the preview endpoint is including the fields data:

{
    "sys": {
        "type": "Array"
    },
    "total": 1,
    "skip": 0,
    "limit": 100,
    "items": [
        {
            "sys": {
                "space": {
                    "sys": {
                        "type": "Link",
                        "linkType": "Space",
                        "id": "ln3pvrc2qpmb"
                    }
                },
                "type": "Entry",
                "id": "1THRfm7l5tWQNd2cM9VyVl",
                "contentType": {
                    "sys": {
                        "type": "Link",
                        "linkType": "ContentType",
                        "id": "production"
                    }
                },
                "revision": 4,
                "createdAt": "2019-02-05T10:47:59.008Z",
                "updatedAt": "2019-02-14T13:06:08.397Z",
                "environment": {
                    "sys": {
                        "id": "master",
                        "type": "Link",
                        "linkType": "Environment"
                    }
                },
                "locale": "en-US"
            },
            "fields": {
                "productionName": "Mike and the Mechanics at New Theatre Oxford",
                "title": {
                    "sys": {
                        "type": "Link",
                        "linkType": "Entry",
                        "id": "HGC4yTNZWm6CCws0qi0iQ"
                    }
                },
                "venue": {
                    "sys": {
                        "type": "Link",
                        "linkType": "Entry",
                        "id": "mbFpTuYsuGmGCacaM40Km"
                    }
                },
                "priceMinimum": 37.65,
                "priceTransactionFee": 3.65,
                "showTimes": [
                    "Tue at 19:30"
                ],
...

the response from the cdn endpoint is not giving any detail - as far as I can see from the UI - this content is Published.

{
    "sys": {
        "type": "Array"
    },
    "total": 1,
    "skip": 0,
    "limit": 100,
    "items": [
        {
            "sys": {
                "space": {
                    "sys": {
                        "type": "Link",
                        "linkType": "Space",
                        "id": "ln3pvrc2qpmb"
                    }
                },
                "id": "1THRfm7l5tWQNd2cM9VyVl",
                "type": "Entry",
                "createdAt": "2019-02-05T10:49:08.064Z",
                "updatedAt": "2019-02-14T13:06:08.397Z",
                "environment": {
                    "sys": {
                        "id": "master",
                        "type": "Link",
                        "linkType": "Environment"
                    }
                },
                "revision": 4,
                "contentType": {
                    "sys": {
                        "type": "Link",
                        "linkType": "ContentType",
                        "id": "production"
                    }
                },
                "locale": "en-US"
            },
            "fields": {}
        }
    ]
}
0 Likes

#4

We had exactly the same problem and it was acknowledged as a bug which was fixed on Feb 19th.

0 Likes