Changes to UID History

Hey everyone,

we were previously able to query document's that had old uid's. Right now if I query any document with a past uid I get nothing back. It only works with the current uid of a document.

As far as I know the 'slugs' feature is deprecated but I can't find anything about it in the documentation. We changed nothing about our setup it just happened over night and now we have a bunch of 404's errors on our site because old uid's get nothing back from the prismic api.

Were there some changes to the api that removed that feature?

Thanks in advance :slight_smile:
Tim

Hi Tim,

You should be able to search for a document by an old UID in the REST API, can you please give us a link example of a document with an old UID?

Looking forward to your reply,
Fares

Hi @Fares, thank you for the fast response!

This one works for example because the uid matches exactly the document: "marketing" UID

In the response I can see the slugs array with all past uid's of the document. If I try "solutions-for-marketing" I get nothing back. No other past uid's seem to work as well it really only works with "marketing" which is the current uid of the document.

Best, Tim

Any updates on this behaviour? :wink:

The links are not working anymore because the ref changed.
These ones work (for now):

1 Like

Hey everyone,

I already tried asking this question here but didn't get much of a response so I'm writing here again.

We were previously able to query document's that had old uid's. Right now if I query any document with a past uid I get nothing back. It only works with the current uid of a document.

As far as I know the 'slugs' feature is deprecated but I can't find anything about it in the documentation. We changed nothing about our setup it just happened over night and now we have a bunch of 404's errors on our site because old uid's get nothing back from the prismic api.

Were there some changes to the api that removed that feature?

This one works for example because the uid matches exactly the document: "marketing" UID

In the response I can see the slugs array with all past uid's of the document. If I try "solutions-for-marketing" I get nothing back. No other past uid's seem to work as well it really only works with "marketing" which is the current uid of the document.

Thanks in advance :slight_smile:
Tim

Hello @tim.richter, I'll take over this conversation since Fares isn't here for the moment.

I ran a test in your endpoint by querying by UID, and I can confirm that there's an odd behavior in the response.

With a new change to the API, this should be solved. Can you try again and see if it's works ok?

2 Likes

This thread is being monitored as an open ticket in the issue tracker. We will update this post as we get more information. If you have a similar use-case, you can ‘Flag’ this topic to reopen.