v25.3.4
v25.3.4
Remove counting courier messages in /admin/courier/messages
We've removed the X-Total-Count
HTTP response header from the /admin/courier/messages
endpoint. This change prevents a costly,
linear scan of the database on every request, which was defeating the purpose of pagination.
Additionally, there is a new configuration field in Kratos: secrets.pagination
which is a list of encryption keys used to
encrypt/decrypt the pagination token. This is not security sensitive and only used to avoid having API clients relying on the
specific implementation of the pagination token. This way the implementation is free to change in the future. If no keys are
configured, a fallback key is transparently used.
Breaking changes
- Clients can no longer rely on the
X-Total-Count
HTTP response header. - The total number of messages is now indeterminate. You can determine the last page when the number of returned items is less than the page size. But note that due to the real-time nature of this data, subsequent calls with identical filters may return different results as the total number of messages can change rapidly.