About the Translation Schema API

Developer Preview
APIs in Developer Preview are subject to change and are not intended for use in production.
Send us your suggestions for improving this API. Your feedback is valuable to us.

 

The Translation Schema API allows you to manage the schema for translating site content. Define the structure and fields of your app's translatable content to ensure consistency and accuracy across different locales. You only need to do this setup once per entity, providing a foundation for all future translations.

You can create schemas for each entity of your app. For example, if you are developing a food delivery app, you may want to create two schemas, one for a menu and another for orders.

With the Translation Schema API, your app can:

  • Create, update, and delete a translation schema.
  • Get an existing translation schema by ID or key.
  • Query your app's schemas.
  • List all schemas associated with a site.

Validations

You can also set validations for fields in the schema. For example, in the schema below, the title field has a minLength of 1, meaning the smallest valid text value for that field must be at least one character long. If validations are defined in the schema, the corresponding content is constrained to those validations. If you add invalid content you'll get a validation error.

Copy
"schema": { "key": { "entityType": "Menu", "scope": "GLOBAL" }, "fields": { "menu-title": { "type": "SHORT_TEXT", "displayName": "Menu Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false } } }

Before you begin

It’s important to note the following points before starting to code:

  • There are no private schemas. All of a site's schemas can be retrieved by calling List Site Schemas.
  • You can only use this API on sites where the Wix user has installed the Wix Multilingual app.

Use cases

Terminology

  • Scope: A schema can have one of two scopes:
    • Site: A custom schema for a specific site.
    • Global: A global schema for all sites.

You can update both site and global schemas, as well as change a site schema to global or vice versa. However, if you need to create a site-specific schema based on an existing global one, create a new schema with a site scope and manually copy the specifications from the existing global one.

  • Schema field: This defines the structure and validation rules for a field within a translation schema. It specifies the type of data (such as text or image) and constraints (such as minimum or maximum length) for each field in the schema. The SchemaField ensures that any content added conforms to the defined format.

  • Fields: A list of fields for the translation schema. The fields property uses a string to map to a SchemaField (Map<string, SchemaField>). The string serves as a key, which you'll need to access each field in the schema and when adding translation content.

Did this help?

Sample Use Cases and Flows

This article presents possible use cases and corresponding sample flows that your app can support. It provides a useful starting point as you plan your app's implementation.

Update a global schema

Suppose you're developing an app that provides promotional campaigns for stores. Your app integrates with Wix Multilingual to allow Wix users to translate promotions for customers. You've already used the Create Schema method to create a GLOBAL schema for all sites. Your schema includes a promotionDetails field that allows stores to provide the fine details of the promotion to the customer. Initially, this field is limited to 256 characters. Due to a recent update in your app, this field now supports up to 1024 characters. You need to update your app's schema to reflect this change:

Call Update Schema with the promotionDetails field, allowing up to 1024 characters.

Copy
curl -X PATCH \ 'https://www.wixapis.com/translation-schema/v1/schemas/8046df3c-7575-4098-a5ab-c91ad8f33c47' \ -H 'Authorization: <AUTH>' \ -H 'Content-Type: application/json' \ --data-binary '{ "schema": { "revision": 3, "fields": { "promotionDetails": { "maxLength": 1024, } } }, }'
  1. Site owners can now provide content for the promotionDetails field with up to 1024 characters in length.
Important:

When updating a schema with a GLOBAL scope, be aware that this change will apply to all sites using this schema. If you need to update a field for only one specific store, consider creating a schema with a SITE scope instead, as explained in the sample flow below.

Create a site schema based on an existing global schema

Suppose you're an app developer providing delivery services for restaurants. Your app integrates with Wix Multilingual to allow Wix users to translate delivery information. You've already used the Create Schema method to create a GLOBAL schema for all sites.

Here's an example schema object:

Copy
{ "schema": { "id": "12345678-90ab-cdef-1234-567890abcdef", "revision": 2, "createdDate": "2024-08-19T12:34:56.789Z", "updatedDate": "2024-08-19T12:34:56.789Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "restaurant-delivery-service", "scope": "GLOBAL" }, "fields": { "delivery_instructions": { "id": "delivery_instructions", "type": "LONG_TEXT", "displayName": "Delivery Instructions", "minLength": 0, "maxLength": 512, "hidden": false, "displayOnly": false }, "courier_tip": { "id": "courier_tip_currency", "type": "SHORT_TEXT", "displayName": "Tip for Courier", "minLength": null, "maxLength": 3, "hidden": false, "displayOnly": false }, "instructions_to_courier": { "id": "instructions_to_courier", "type": "LONG_TEXT", "displayName": "Instructions to Courier", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false } } } }

Now let's say the restaurant owner wants to disable the option for customers to tip couriers, and requests that you remove the courier_tip field from the schema. Since the schema has a GLOBAL scope, updating it would affect all sites using it. To avoid this, you'll create a site-specific schema based on the existing global one as follows:

  1. Call the Create Schema method with a SITE scope to create a custom schema for the restaurant's site. Copy all the fields from the existing schema except for the courier_tip field.
Copy
curl -X POST \ 'https://www.wixapis.com/translation-schema/v1/schemas' \ -H 'Authorization: <AUTH>' \ -H 'wix-site-id: <SITEID>' \ -H 'Content-Type: application/json' \ --data-binary '{ "schema": { "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "restaurant-delivery-service", "scope": "SITE" }, "fields": { "delivery_instructions": { "id": "delivery_instructions", "type": "LONG_TEXT", "displayName": "Delivery Instructions", "minLength": 0, "maxLength": 512, "hidden": false, "displayOnly": false }, "instructions_to_courier": { "id": "instructions_to_courier", "type": "LONG_TEXT", "displayName": "Instructions to Courier", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false } } } }'
  1. After creating the site-specific schema, use the Translation Content API to add your app's default content to the newly created schema. Then, ask the restaurant owner to add their translated content to ensure that the new delivery instructions are available in all supported locales.

To summarize, updating the schema for a specific site removes the courier_tip field only for that site. Other sites using the global schema will still have the option to include tips. This prevents unintended changes for all app users.

Did this help?

Translation Schema: Supported Filters and Sorting

This article covers field support for filtering and sorting in the Translation Schema API.

The following table shows field support for filters and sorting for the translation schema object when using Query Schemas:

FieldSupported FiltersSortable
ideq, ne, exists, in, hasSome, startsWith, ascending, descendingSortable
key.appIdeq, ne, exists, in, hasSome, startsWith, ascending, descendingSortable
key.entityTypeeq, ne, exists, in, hasSome, startsWith, ascending, descendingSortable
key.scopeeq, ne, exists, in, hasSome, startsWith, ascending, descendingSortable
hiddeneq, ne, exists, in, hasSome, startsWith, ascending, descendingSortable
parentIdeq, ne, exists, in, hasSome, startsWith, ascending, descendingSortable
Did this help?

Translation Schema API: Errors

This table outlines errors that might be issued when calling the Translation Schema API. The list includes error codes, messages, and troubleshooting guidance to help you resolve these issues.

HTTP STATUS
ERROR NAME
DESCRIPTION & TROUBLESHOOTING
BAD_REQUEST (400)SchemaRevisionMissingExceptionThe schema entity in the Create or Update methods violates validation rules, such as missing a revision value when calling the Update method. Ensure all properties are valid.
BAD_REQUEST (400)SchemaFieldIdsWithProhibitedCharactersExceptionField IDs contain invalid characters. Field ID must contain only a-zA-Z0-9_-)(). Remove the invalid characters.
BAD_REQUEST (400)SchemaFieldIdsWithInvalidBracketsOrderExceptionField ID can't contain nested parentheses. Ensure field IDs don't include nested parentheses.
BAD_REQUEST (400)SchemaFieldWithInvalidFormatExceptionInvalid field value format. Update the field value to match the required format.
BAD_REQUEST (400)SchemaFieldMinLengthGreaterEqualToMaxLengthExceptionThe field's minimum length is greater than or equal to its maximum length. minLength must be smaller than maxLength. Ensure the field's minimum length is smaller than its maximum length.
BAD_REQUEST (400)SchemaFieldUnknownTypeExceptionUnknown or undefined field type. Provide a valid field type.
BAD_REQUEST (400)SchemaPreviewFieldNonExistentIdExceptionThe preview field doesn't match any field in the schema. Ensure all preview fields reference existing field IDs in the schema.
BAD_REQUEST (400)SchemaPreviewFieldTypeMismatchExceptionInvalid preview field type. Ensure it matches one of the allowed types for this field.
NOT_FOUND (404)EntityNotFoundRuntimeExceptionSchema not found. Verify that the schema ID is correct, and that the schema exists in the system.
PERMISSION_DENIED (403)InsufficientPermissionsExceptionInsufficient permissions to perform the action. Ensure your app has the necessary permissions for the requested operation.
INTERNAL (500)InvalidIdGeneratedExceptionThe system failed to generate a unique ID for the new schema. Retry the operation.

General Troubleshooting

If you encounter any of these errors:

  1. Check that all required fields are present and correctly formatted in your schema definition.
  2. Ensure that field IDs, types, and formats comply with the specified validations.
  3. Verify that you have the necessary permissions for the requested operation.
  4. If the error persists, contact support with the specific error message and details of your operation.
Did this help?

Schema Object


Properties
idstringRead-onlyformat GUID

Translation schema ID.


keyKey

Translation schema unique key identifier.


fieldsMap <string, SchemaField>minItems 1maxItems 1000format map

List of fields for the translation schema. This property uses a string to map to a SchemaField (Map<string, SchemaField>). The string serves as a key, which you'll need to access each field in the schema and when adding translation content.


previewFieldsPreviewFields

Fields displayed in content previews. For example, a product name for a product translation schema.


hiddenboolean

Whether the translation schema is hidden from the site.

Default: false


displayNamestringmaxLength 100

Translation schema name displayed in the Translation Manager.


parentIdstringformat GUID

A reference to the parent schema. For example, if the schema is for a menu item, this property would contain the schema ID of the menu it belongs to.


revisionintegerRead-onlyformat int64

Revision number, which increments by 1 each time the schema is updated. To prevent conflicting changes, the existing revision must be used when updating a schema.


createdDatestringRead-onlyformat date-time

Date and time the translation schema was created.


updatedDatestringRead-onlyformat date-time

Date and time the translation schema was updated.


duplicateContentboolean

Whether to duplicate the translated content when a site containing the translation schema and content is duplicated.

Default: false

Schema
JSON
{ "schema": { "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "revision": 1, "createdDate": "2019-10-30T17:22:10.299Z", "updatedDate": "2019-10-30T17:22:10.299Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "Product", "scope": "GLOBAL" }, "fields": { "title": { "id": "title", "type": "SHORT_TEXT", "display_name": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "id": "description", "type": "RICH_CONTENT", "display_name": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "id": "image()", "type": "IMAGE", "displayName": "Product's Image", "minLength": null, "maxLength": null, "hidden": false, "displayOnly": false } } } }
Did this help?

POST

Create Schema


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Creates a translation schema.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Wix Multilingual - Translation Schema Write
Learn more about app permissions.
Endpoint
POST
https://www.wixapis.com/translation-schema/v1/schemas

Body Params
schemaSchemaRequired

Translation schema to create.

Response Object
schemaSchema

Newly created translation schema.

Request
cURL
curl -X POST \ 'https://www.wixapis.com/translation-schema/v1/schemas' \ -H 'Authorization: <AUTH>' \ -H 'Content-Type: application/json' \ --data-binary '{ "schema": { "key": { "entityType": "Product", "scope": "GLOBAL" }, "fields": { "title": { "type": "SHORT_TEXT", "displayName": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "type": "RICH_CONTENT", "displayName": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "type": "IMAGE", "displayName": "Product Image", "hidden": false, "displayOnly": false } } } }'
Response
JSON
{ "schema": { "id": "9428de50-b559-43f7-bec4-1cb21a23f72f", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "Product", "scope": "GLOBAL" }, "fields": { "title": { "id": "title", "type": "SHORT_TEXT", "displayName": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "id": "description", "type": "RICH_CONTENT", "displayName": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "id": "image()", "type": "IMAGE", "displayName": "Product Image", "hidden": false, "displayOnly": false } }, "hidden": false, "revision": "1", "createdDate": "2024-09-16T10:44:08.532Z", "updatedDate": "2024-09-16T10:44:08.532Z", "duplicateContent": false } }
Event TriggersThis method triggers the following events:
Did this help?

GET

Get Schema


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a translation schema by ID.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Wix Multilingual - Translation Schema Read
Learn more about app permissions.
Endpoint
GET
https://www.wixapis.com/translation-schema/v1/schemas/{schemaId}

Path Params
schemaIdstringRequired

ID of the translation schema to retrieve.

Response Object
schemaSchema

The requested translation schema.

Get Schema By ID
Request
cURL
curl -X GET \ 'https://www.wixapis.com/translation-schema/v1/schemas/8046df3c-7575-4098-a5ab-c91ad8f33c47' \ -H 'Authorization: <AUTH>' \
Response
JSON
{ "schema": { "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "revision": 1, "createdDate": "2019-10-30T17:22:10.299Z", "updatedDate": "2019-10-30T17:22:10.299Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "Product", "scope": "GLOBAL" }, "fields": { "title": { "id": "title", "type": "SHORT_TEXT", "displayName": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "id": "description", "type": "RICH_CONTENT", "displayName": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "id": "image()", "type": "IMAGE", "displayName": "Product's Image", "minLength": null, "maxLength": null, "hidden": false, "displayOnly": false } } } }
Did this help?

DELETE

Delete Schema


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Deletes a translation schema.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Wix Multilingual - Translation Schema Write
Learn more about app permissions.
Endpoint
DELETE
https://www.wixapis.com/translation-schema/v1/schemas/{schemaId}

Path Params
schemaIdstringRequired

ID of the translation schema to delete.

Response Object
Returns an empty object.
Delete Schema
Request
cURL
curl -X DELETE \ 'https://www.wixapis.com/translation-schema/v1/schemas/8046df3c-7575-4098-a5ab-c91ad8f33c47' \ -H 'Authorization: <AUTH>' \
Response
JSON
{}
Event TriggersThis method triggers the following events:
Did this help?

GET

Get Schema By Key


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a translation schema by key.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Wix Multilingual - Translation Schema Read
Learn more about app permissions.
Endpoint
GET
https://www.wixapis.com/translation-schema/v1/schemas/app-id/{key.appId}/entity-type/{key.entityType}/scope/{key.scope}

Path Params
key.appIdstringRequired

ID of the app that created the schema.


key.entityTypestringRequired

A unique name defined by the app developer to differentiate translation schemas for various entities within their app. For example, if an app developer is creating a translation schema for blog posts, the entityType can be 'blog-posts'.


key.scopestringRequired

Scope of the translation schema. Supported values:

  • GLOBAL: A global schema for all sites.
  • SITE: A custom schema for a specific site.
Query Params
key.entityTypestringminLength 1maxLength 80

A unique name defined by the app developer to differentiate translation schemas for various entities within their app. For example, if an app developer is creating a translation schema for blog posts, the entityType can be 'blog-posts'.


key.scopestring

Scope of the translation schema. Supported values:

  • GLOBAL: A global schema for all sites.
  • SITE: A custom schema for a specific site.
Response Object
schemaSchema

The requested translation schema.

Get Schema By Key
Request
cURL
curl -X GET \ 'https://www.wixapis.com/translation-schema/v1/schemas/app-id/4ad2dfe1-a943-45a8-94ac-f1dd8b78821b/entity-type/Product/scope/GLOBAL' \ -H 'Authorization: <AUTH>' \
Response
JSON
{ "schema": { "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "revision": 1, "createdDate": "2019-10-30T17:22:10.299Z", "updatedDate": "2019-10-30T17:22:10.299Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "Product", "scope": "GLOBAL" }, "fields": { "title": { "id": "title", "type": "SHORT_TEXT", "displayName": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "id": "description", "type": "RICH_CONTENT", "displayName": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "id": "image()", "type": "IMAGE", "displayName": "Product's Image", "minLength": null, "maxLength": null, "hidden": false, "displayOnly": false } } "hidden": false, "revision": "1", "createdDate": "2024-09-16T10:52:45.680Z", "updatedDate": "2024-09-16T10:52:45.680Z", "duplicateContent": false } }
Did this help?

PATCH

Update Schema


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Updates a translation schema.

To remove a field, pass the field key with an empty object as the value. For example:

Copy
{ "fields": { "title": {} } }
Caution:

Removing a schema field makes the corresponding content field unavailable.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Wix Multilingual - Translation Schema Write
Learn more about app permissions.
Endpoint
PATCH
https://www.wixapis.com/translation-schema/v1/schemas/{schema.id}

Path Params
schema.idstringRequired

Translation schema ID.

Body Params
schemaSchemaRequired

Translation schema to update.

Response Object
schemaSchema

Updated Schema.

Update Schema
Request
cURL
curl -X PATCH \ 'https://www.wixapis.com/translation-schema/v1/schemas/8046df3c-7575-4098-a5ab-c91ad8f33c47' \ -H 'Authorization: <AUTH>' \ -H 'Content-Type: application/json' \ --data-binary '{ "schema": { "displayName": "A New Display Name", "revision": 1, }, }'
Response
JSON
{ "schema": { "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "revision": 1, "createdDate": "2019-10-30T17:22:10.299Z", "updatedDate": "2019-10-30T17:22:10.299Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "Product", "scope": "GLOBAL" }, "display_name": "A new Display Name", "fields": { "title": { "id": "title", "type": "SHORT_TEXT", "displayName": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "id": "description", "type": "RICH_CONTENT", "displayName": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "id": "image()", "type": "IMAGE", "displayName": "Product's Image", "minLength": null, "maxLength": null, "hidden": false, "displayOnly": false } } } }
Event TriggersThis method triggers the following events:
Did this help?

POST

Query Schemas


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a list of schemas, given the provided paging, filtering, and sorting. Up to 100 schemas can be returned per request.

Note:

This method can retrieve all schemas with a GLOBAL scope and schemas with a SITE scope for the site the API request is authorized to access.

The default sort is id in ASC.

For a detailed list of supported operations, see Translation Schema: Supported Filters and Sorting. To learn how to query translation schemas, see API Query Language.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Wix Multilingual - Translation Schema Read
Learn more about app permissions.
Endpoint
POST
https://www.wixapis.com/translation-schema/v1/schemas/query

Body Params
queryQuery

Query options.

Response Object
schemasArray <Schema>

List of translation schemas.


pagingMetadataPagingMetadata

Paging metadata for the next page of results.

Query Schema
Request
cURL
curl -X POST \ 'https://www.wixapis.com/translation-schema/v1/schemas/query' \ -H 'Authorization: <AUTH>' \ -H 'Content-Type: application/json' \ --data-binary '{ "query": { "filter": { "key.appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b" }, } }'
Response
JSON
{ "schema": { "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "revision": 1, "createdDate": "2019-10-30T17:22:10.299Z", "updatedDate": "2019-10-30T17:22:10.299Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "Product", "scope": "GLOBAL" }, "fields": { "title": { "id": "title", "type": "SHORT_TEXT", "displayName": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "id": "description", "type": "RICH_CONTENT", "displayName": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "id": "image()", "type": "IMAGE", "displayName": "Product's Image", "minLength": null, "maxLength": null, "hidden": false, "displayOnly": false } } } }
Did this help?

GET

List Site Schemas


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a list of all translation schemas associated with a site, regardless of which app created them.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Wix Multilingual - Translation Content + Published Content Read
Wix Multilingual - Write Translation Content
Learn more about app permissions.
Endpoint
GET
https://www.wixapis.com/translation-schema/v1/schemas/site

Query Params
paging.limitintegerminimum 0maximum 100format int32

Maximum number of items to return in the results.


paging.cursorstringmaxLength 16000

Pointer to the next or previous page in the list of results.

Pass the relevant cursor token from the pagingMetadata object in the previous call's response. Not relevant for the first request.


appIdstring

ID of app that created the schema.


entityTypestring

A unique name defined by the app developer to differentiate translation schemas for various entities within their app. For example, if an app developer is creating a translation schema for blog posts, the entityType can be 'blog-posts'.


scopestring

Scope of the translation schema. Supported values:

  • GLOBAL: A global schema for all sites.
  • SITE: A custom schema for a specific site.
Response Object
schemasArray <Schema>

List of translation schemas.


pagingMetadataPagingMetadata

Paging metadata for the next page of results.

List Site Schemas

List all schemas installed on a site, including both SITE and GLOBAL scopes.

Request
cURL
curl -X GET \ 'https://www.wixapis.com/translation-schema/v1/schemas/site' \ -H 'Authorization: <AUTH>' \ -H 'Content-Type: application/json' \
Response
JSON
{ "schemas": [ { "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "revision": 1, "createdDate": "2019-10-30T17:22:10.299Z", "updatedDate": "2019-10-30T17:22:10.299Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "Product", "scope": "GLOBAL" }, "fields": { "title": { "id": "title", "type": "SHORT_TEXT", "displayName": "Title", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "description": { "id": "description", "type": "RICH_CONTENT", "displayName": "Description", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "image()": { "id": "image()", "type": "IMAGE", "displayName": "Product's Image", "minLength": null, "maxLength": null, "hidden": false, "displayOnly": false } } }, { "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "revision": 1, "createdDate": "2019-10-30T17:22:10.299Z", "updatedDate": "2019-10-30T17:22:10.299Z", "key": { "appId": "4ad2dfe1-a943-45a8-94ac-f1dd8b78821b", "entityType": "My-Pet-Collection", "scope": "SITE" }, "fields": { "petMame": { "id": "petMame", "type": "SHORT_TEXT", "displayName": "Pet Name", "minLength": 1, "maxLength": 54, "hidden": false, "displayOnly": false }, "petType": { "id": "description", "type": "LONG_TEXT", "displayName": "Pet Type (cat, dog, etc)", "minLength": 1, "maxLength": 256, "hidden": false, "displayOnly": false }, "medicalState": { "id": "medicalState", "type": "RICH_CONTENT", "displayName": "The pet's medical state", "minLength": null, "maxLength": null, "hidden": false, "displayOnly": false } } } ] }
Did this help?

Schema Created


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when translation schema is created.

Permissions
Wix Multilingual - Translation Schema Read
Learn more about app permissions.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring

Unique event ID. Allows clients to ignore duplicate webhooks.


entityFqdnstring

Fully qualified domain name of the entity associated with the event. Expected wix.multilingual.translation.v1.schema.


slugstring

Event name. Expected created.


entityIdstring

ID of the entity associated with the event.


eventTimestringformat date-time

Event timestamp.


triggeredByAnonymizeRequestboolean

Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).


originatedFromstring

If present, indicates the action that triggered the event.


createdEventCreatedEvent

Event information.

Event Body

The data payload will include the following as an encoded JWT:

JSON
{ "data": { "eventType": "wix.multilingual.translation.v1.schema_created", "instanceId": "<app-instance-id>", "data": "<stringified-JSON>", // The identity field is sent as a stringified JSON "identity": { "identityType": "<identityType>", // ANONYMOUS_VISITOR, MEMBER, WIX_USER, APP "anonymousVisitorId": "<anonymousVisitorId>", // in case of ANONYMOUS_VISITOR "memberId": "<memberId>", // in case of MEMBER "wixUserId": "<wixUserId>", // in case of WIX_USER "appId": "<appId>" // in case of APP } } }

SchemaCreated
JSON
{ "id": "52269077-05f2-4b59-ba4f-36ef8c4c1e11", "entityFqdn": "wix.multilingual.translation.v1.schema", "slug": "created", "entityId": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "createdEvent": { "entityAsJson": "{\"schema\":{\"id\":\"8046df3c-7575-4098-a5ab-c91ad8f33c47\",\"revision\":1,\"createdDate\":\"2019-10-30T17:22:10.299Z\",\"updatedDate\":\"2019-10-30T17:22:10.299Z\",\"key\": {\"app_id\": \"4ad2dfe1-a943-45a8-94ac-f1dd8b78821b\", \"entity_type\": \"Product\", \"scope\": \"GLOBAL\"}, \"fields\": {\"title\": {\"id\": \"title\", \"type\": \"SHORT_TEXT\", \"display_name\": \"Title\", \"min_length\": 1, \"max_length\": 54, \"hidden\": false, \"display_only\": false}, \"entity.description\": {\"id\": \"description\", \"type\": \"RICH_CONTENT\", \"display_name\": \"Description\", \"min_length\": 1, \"max_length\": 256, \"hidden\": false, \"display_only\": false}, \"image()\": {\"id\": \"image()\", \"type\": \"IMAGE\", \"display_name\": \"Product's Image\", \"min_length\": null, \"max_length\": null, \"hidden\": false, \"display_only\": false}},\"preview_fields\": {\"title_field_id\": \"title\"}, \"hidden\": \"false\", \"display_name\": \"My Product\", \"parent_id\": \"1601ff9c-0b14-449b-93a5-4d000a5456fa\"}}" }, "eventTime": "2020-10-18T13:40:58.304800Z", "triggeredByAnonymizeRequest": false }
Did this help?

Schema Deleted


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when translation schema is deleted.

Permissions
Wix Multilingual - Translation Schema Read
Learn more about app permissions.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring

Unique event ID. Allows clients to ignore duplicate webhooks.


entityFqdnstring

Fully qualified domain name of the entity associated with the event. Expected wix.multilingual.translation.v1.schema.


slugstring

Event name. Expected deleted.


entityIdstring

ID of the entity associated with the event.


eventTimestringformat date-time

Event timestamp.


triggeredByAnonymizeRequestboolean

Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).


originatedFromstring

If present, indicates the action that triggered the event.


deletedEventstruct

Event information.

Event Body

The data payload will include the following as an encoded JWT:

JSON
{ "data": { "eventType": "wix.multilingual.translation.v1.schema_deleted", "instanceId": "<app-instance-id>", "data": "<stringified-JSON>", // The identity field is sent as a stringified JSON "identity": { "identityType": "<identityType>", // ANONYMOUS_VISITOR, MEMBER, WIX_USER, APP "anonymousVisitorId": "<anonymousVisitorId>", // in case of ANONYMOUS_VISITOR "memberId": "<memberId>", // in case of MEMBER "wixUserId": "<wixUserId>", // in case of WIX_USER "appId": "<appId>" // in case of APP } } }
Did this help?

Schema Updated


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when translation schema is updated.

Permissions
Wix Multilingual - Translation Schema Read
Learn more about app permissions.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring

Unique event ID. Allows clients to ignore duplicate webhooks.


entityFqdnstring

Fully qualified domain name of the entity associated with the event. Expected wix.multilingual.translation.v1.schema.


slugstring

Event name. Expected updated.


entityIdstring

ID of the entity associated with the event.


eventTimestringformat date-time

Event timestamp.


triggeredByAnonymizeRequestboolean

Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).


originatedFromstring

If present, indicates the action that triggered the event.


updatedEventUpdatedEvent

Event information.

Event Body

The data payload will include the following as an encoded JWT:

JSON
{ "data": { "eventType": "wix.multilingual.translation.v1.schema_updated", "instanceId": "<app-instance-id>", "data": "<stringified-JSON>", // The identity field is sent as a stringified JSON "identity": { "identityType": "<identityType>", // ANONYMOUS_VISITOR, MEMBER, WIX_USER, APP "anonymousVisitorId": "<anonymousVisitorId>", // in case of ANONYMOUS_VISITOR "memberId": "<memberId>", // in case of MEMBER "wixUserId": "<wixUserId>", // in case of WIX_USER "appId": "<appId>" // in case of APP } } }

SchemaUpdated
JSON
{ "id": "52269077-05f2-4b59-ba4f-36ef8c4c1e11", "entityFqdn": "wix.multilingual.translation.v1.schema", "slug": "updated", "entityId": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "updatedEvent": { "currentEntityAsJson": "{\"schema\":{\"id\":\"8046df3c-7575-4098-a5ab-c91ad8f33c47\",\"revision\":1,\"createdDate\":\"2019-10-30T17:22:10.299Z\",\"updatedDate\":\"2019-10-30T17:22:10.299Z\",\"key\": {\"app_id\": \"4ad2dfe1-a943-45a8-94ac-f1dd8b78821b\", \"entity_type\": \"Product\", \"scope\": \"GLOBAL\"}, \"fields\": {\"title\": {\"id\": \"title\", \"type\": \"SHORT_TEXT\", \"display_name\": \"Title\", \"min_length\": 1, \"max_length\": 54, \"hidden\": false, \"display_only\": false}, \"entity.description\": {\"id\": \"description\", \"type\": \"RICH_CONTENT\", \"display_name\": \"Description\", \"min_length\": 1, \"max_length\": 256, \"hidden\": false, \"display_only\": false}, \"image()\": {\"id\": \"image()\", \"type\": \"IMAGE\", \"display_name\": \"Product's Image\", \"min_length\": null, \"max_length\": null, \"hidden\": false, \"display_only\": false}},\"preview_fields\": {\"title_field_id\": \"title\"}, \"hidden\": \"false\", \"display_name\": \"My Product\", \"parent_id\": \"1601ff9c-0b14-449b-93a5-4d000a5456fa\"}}" }, "eventTime": "2020-10-18T13:40:58.304800Z", "triggeredByAnonymizeRequest": false }
Did this help?