You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there an API to determine the language set by the user under /preferences/appearance? I'm asking as this seems to have an effect on translations?
There doesn't seem to be an API-endpoint to fetch the UI-language set by the user under /settings/preferences/appearance. This language seems to have an effect on translations.
When I set this language to German and want to translate a German toot from the iOS-app, I get a HTTP status-code 403 and a JSON that looks like this: {"error": "This action is not allowed"}. Translating an English toot works.
If we knew this UI-language in the app, we could hide the "Translate"-option from the user. If we don't know that language, the only, but unreliable way I can think of, would be to use the device-language.
Regardless of providing this value via API, you could also think about letting the translation-services "translate" from language A to language A so that translate doesn't return an error/403.
Thank you!
Motivation
3rd-party-developers who want to use the built-in translate-function in their apps, would benefit from this.
Mastodon for iOS could hide the translate-option for those status-posts (and I'm pretty sure that Android could benefit from this, too!)
The text was updated successfully, but these errors were encountered:
Pitch
Is there an API to determine the language set by the user under /preferences/appearance? I'm asking as this seems to have an effect on translations?
There doesn't seem to be an API-endpoint to fetch the UI-language set by the user under
/settings/preferences/appearance
. This language seems to have an effect on translations.When I set this language to German and want to translate a German toot from the iOS-app, I get a HTTP status-code
403
and a JSON that looks like this:{"error": "This action is not allowed"}
. Translating an English toot works.If we knew this UI-language in the app, we could hide the "Translate"-option from the user. If we don't know that language, the only, but unreliable way I can think of, would be to use the device-language.
Regardless of providing this value via API, you could also think about letting the translation-services "translate" from language A to language A so that
translate
doesn't return an error/403.Thank you!
Motivation
The text was updated successfully, but these errors were encountered: