Where would we translate error messages from API responses?

For example, if I try to hit the auth endpoint with the wrong password, I will get a 400 Bad Request with response object including the following properties, which I would like to show in the front-end application UI:

key: "error.user.password.notSame"
message: "The passwords do not match"

Are these messages translated in most common languages, e.g. French, German, Spanish etc. and available automatically e.g. via a URL param?

If not, is there a best place for me to add these translations? e.g. language variables? Can I find an index of these messages so I can make sure we translate all of them?

Yes! You can find all keys and their translations in `/kirby/i18n/translations.

Are you using Kirby headless?

Thanks, Sonja. Yes, I am using Kirby headless.

So, if I set X-Language header on my auth request, will any messages etc. come back in that language?

I don’t know if the X-language header is respected for those messages, but it should be.