Update content by field via API/Cli

Hi there

We would like to use squidex for our next customer projects. Mostly we would like to use it the classic way, in a sense that the user edits the content in the admin panel.

We also have a special use case: we would like to enable the user to translate the fixed strings in our Android app directly in squidex. The idea is to use a script/cli that inserts the translation keys in Squidex and then let the user enter the translated values.

The content has the following format:

“data”: {
“key”: {
“iv”: “TranslationKey”
“value”: {
“en”: “TranslationValue”

I fiddled around with squidex cli and was able to import a set of JSON strings. However to make the use case work I would need to find an existing content via a field value (in the example above find the content with the field key = TranslationKey) or create a new content if no content with this criteria exists. So the question is: is there an API to manipulate specific contents via API/cli?

Is this somehow doable with squidex?

Thanks for your help

The CLI is for management processes, but it can done via the API.

I would recommend to configure the TranslationKey as unique field.

Then you can just make make an insert. If the key already exists, you will get back a 400, which you can ignore.

To find the content via key you can use the query system: https://docs.squidex.io/02-documentation/developer-guides/api-overview/api