export interface Schema { /** * Translation schema ID. * @readonly */ id?: string | null; /** Translation schema unique key identifier. */ key?: SchemaKey; /** List of fields for the translation schema. This property uses a string to map to a `SchemaField` (`Map`). The string serves as a key, which you'll need to access each field in the schema and when adding translation content. */ fields?: Record; /** Fields displayed in content previews. For example, a product name for a product translation schema. */ previewFields?: PreviewFields; /** * Whether the translation schema is hidden from the site. * * Default: `false` */ hidden?: boolean | null; /** Translation schema name displayed in the [Translation Manager](https://support.wix.com/en/article/wix-multilingual-using-the-translation-manager). */ displayName?: string | null; /** 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. */ parentId?: string | null; /** * 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. * @readonly */ revision?: string | null; /** * Date and time the translation schema was created. * @readonly */ createdDate?: Date | null; /** * Date and time the translation schema was updated. * @readonly */ updatedDate?: Date | null; /** * Whether to duplicate the translated content when a site containing the translation schema and content is duplicated. * * Default: `false` */ duplicateContent?: boolean | null; } export interface SchemaKey { /** * ID of the app that created the schema. * @readonly */ appId?: string; /** 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'`. */ entityType?: string; /** * Scope of the translation schema. * Supported values: * + `GLOBAL`: A global schema for all sites. * + `SITE`: A custom schema for a specific site. */ scope?: SchemaScope; } export declare enum SchemaScope { UNKNOWN_SCOPE = "UNKNOWN_SCOPE", /** Global schema for all sites. */ GLOBAL = "GLOBAL", /** Custom schema for a specific site. */ SITE = "SITE" } export interface SchemaField { /** * Field ID. Validated according to Regex `^[A-Za-z0-9-_)(]+$`. Field IDs may contain parentheses to reference repeated items, such as images. These parentheses can't be nested and each opening parenthesis must be followed by a closing one. For example, `title()()` is valid, while `title)(` and `title(())` aren't valid. The value inside the parenthesis is validated according to Regex `^[^)(\\]\\[\\.]+$`. * @readonly */ id?: string; /** **Required.** Field type. */ type?: FieldType; /** Field name displayed in the [Translation Manager](https://support.wix.com/en/article/wix-multilingual-using-the-translation-manager). */ displayName?: string | null; /** Field group name. */ groupName?: string | null; /** Field minimum text length. */ minLength?: number | null; /** Field maximum text length. */ maxLength?: number | null; /** Field format. Content is validated based on the format set here in the field schema. For example, if the format is `EMAIL`, then the content for this field must be a valid email address. */ format?: string | null; /** Whether the field is hidden from the site. Hidden fields are still validated. */ hidden?: boolean; /** Whether the field is read-only, and not intended to be translated. For example, an image. Use this field when you want an image to remain in the [Translation Manager](https://support.wix.com/en/article/wix-multilingual-using-the-translation-manager) for context, but without being translated. */ displayOnly?: boolean; /** Field index. Use for cases where the order of the fields are relevant. */ index?: number | null; } export declare enum FieldType { /** Undefined field type */ UNDEFINED_TYPE = "UNDEFINED_TYPE", /** Short plain text displayed as a single line in the UI. */ SHORT_TEXT = "SHORT_TEXT", /** Long plain text displayed as multiple lines in the UI. */ LONG_TEXT = "LONG_TEXT", /** Long text including styles, images, and links. */ HTML = "HTML", /** Rich-Content using the Wix Ricos format. */ RICH_CONTENT = "RICH_CONTENT", /** Wix Media Manager image. */ IMAGE = "IMAGE", /** Image URL without metadata. */ IMAGE_LINK = "IMAGE_LINK", /** Wix Media Manager video. */ VIDEO = "VIDEO", /** Wix Media Manager document. */ DOCUMENT = "DOCUMENT" } export interface PreviewFields { /** ID of the field representing the schema's title. */ titleFieldId?: string | null; /** ID of the field representing the schema's image. */ imageFieldId?: string | null; } export interface CreateSchemaRequest { /** Translation schema to create. */ schema: Schema; } export interface CreateSchemaResponse { /** Newly created translation schema. */ schema?: Schema; } export interface GetSchemaRequest { /** ID of the translation schema to retrieve. */ schemaId: string; } export interface GetSchemaResponse { /** The requested translation schema. */ schema?: Schema; } export interface GetSchemaByKeyRequest { /** ID of the translation schema to retrieve. */ key: SchemaKey; } export interface GetSchemaByKeyResponse { /** The requested translation schema. */ schema?: Schema; } export interface UpdateSchemaRequest { /** Translation schema to update. */ schema: Schema; } export interface UpdateSchemaResponse { /** Updated Schema. */ schema?: Schema; } export interface DeleteSchemaRequest { /** ID of the translation schema to delete. */ schemaId: string; } export interface DeleteSchemaResponse { } export interface QuerySchemasRequest { /** Query options. */ query?: CursorQuery; } export interface CursorQuery extends CursorQueryPagingMethodOneOf { /** * Cursor paging options. * * Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging). */ cursorPaging?: CursorPaging; /** * Filter object. * * Learn more about the [filter section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section). */ filter?: Record | null; /** * Sort object. * * Learn more about the [sort section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section). */ sort?: Sorting[]; } /** @oneof */ export interface CursorQueryPagingMethodOneOf { /** * Cursor paging options. * * Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging). */ cursorPaging?: CursorPaging; } export interface Sorting { /** Name of the field to sort by. */ fieldName?: string; /** Sort order. */ order?: SortOrder; } export declare enum SortOrder { ASC = "ASC", DESC = "DESC" } export interface CursorPaging { /** Maximum number of items to return in the results. */ limit?: number | null; /** * 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. */ cursor?: string | null; } export interface QuerySchemasResponse { /** List of translation schemas. */ schemas?: Schema[]; /** Paging metadata for the next page of results. */ pagingMetadata?: CursorPagingMetadata; } export interface CursorPagingMetadata { /** Number of items returned in current page. */ count?: number | null; /** Cursor strings that point to the next page, previous page, or both. */ cursors?: Cursors; /** * Whether there are more pages to retrieve following the current page. * * + `true`: Another page of results can be retrieved. * + `false`: This is the last page. */ hasNext?: boolean | null; } export interface Cursors { /** Cursor string pointing to the next page in the list of results. */ next?: string | null; /** Cursor pointing to the previous page in the list of results. */ prev?: string | null; } export interface ListSiteSchemasRequest { /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ paging?: CursorPaging; /** ID of app that created the schema. */ appId?: string | null; /** 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'`. */ entityType?: string | null; /** * Scope of the translation schema. * Supported values: * + `GLOBAL`: A global schema for all sites. * + `SITE`: A custom schema for a specific site. */ scope?: SchemaScope; } export interface ListSiteSchemasResponse { /** List of translation schemas. */ schemas?: Schema[]; /** Paging metadata for the next page of results. */ pagingMetadata?: CursorPagingMetadata; } export interface MetaSiteSpecialEvent extends MetaSiteSpecialEventPayloadOneOf { /** Emitted on a meta site creation. */ siteCreated?: SiteCreated; /** Emitted on a meta site transfer completion. */ siteTransferred?: SiteTransferred; /** Emitted on a meta site deletion. */ siteDeleted?: SiteDeleted; /** Emitted on a meta site restoration. */ siteUndeleted?: SiteUndeleted; /** Emitted on the first* publish of the meta site (* switching from unpublished to published state). */ sitePublished?: SitePublished; /** Emitted on a meta site unpublish. */ siteUnpublished?: SiteUnpublished; /** Emitted when meta site is marked as template. */ siteMarkedAsTemplate?: SiteMarkedAsTemplate; /** Emitted when meta site is marked as a WixSite. */ siteMarkedAsWixSite?: SiteMarkedAsWixSite; /** Emitted when an application is provisioned (installed). */ serviceProvisioned?: ServiceProvisioned; /** Emitted when an application is removed (uninstalled). */ serviceRemoved?: ServiceRemoved; /** Emitted when meta site name (URL slug) is changed. */ siteRenamedPayload?: SiteRenamed; /** Emitted when meta site was permanently deleted. */ hardDeleted?: SiteHardDeleted; /** Emitted on a namespace change. */ namespaceChanged?: NamespaceChanged; /** Emitted when Studio is attached. */ studioAssigned?: StudioAssigned; /** Emitted when Studio is detached. */ studioUnassigned?: StudioUnassigned; /** A meta site id. */ metaSiteId?: string; /** A meta site version. Monotonically increasing. */ version?: string; /** A timestamp of the event. */ timestamp?: string; /** * TODO(meta-site): Change validation once validations are disabled for consumers * More context: https://wix.slack.com/archives/C0UHEBPFT/p1720957844413149 and https://wix.slack.com/archives/CFWKX325T/p1728892152855659 */ assets?: Asset[]; } /** @oneof */ export interface MetaSiteSpecialEventPayloadOneOf { /** Emitted on a meta site creation. */ siteCreated?: SiteCreated; /** Emitted on a meta site transfer completion. */ siteTransferred?: SiteTransferred; /** Emitted on a meta site deletion. */ siteDeleted?: SiteDeleted; /** Emitted on a meta site restoration. */ siteUndeleted?: SiteUndeleted; /** Emitted on the first* publish of the meta site (* switching from unpublished to published state). */ sitePublished?: SitePublished; /** Emitted on a meta site unpublish. */ siteUnpublished?: SiteUnpublished; /** Emitted when meta site is marked as template. */ siteMarkedAsTemplate?: SiteMarkedAsTemplate; /** Emitted when meta site is marked as a WixSite. */ siteMarkedAsWixSite?: SiteMarkedAsWixSite; /** Emitted when an application is provisioned (installed). */ serviceProvisioned?: ServiceProvisioned; /** Emitted when an application is removed (uninstalled). */ serviceRemoved?: ServiceRemoved; /** Emitted when meta site name (URL slug) is changed. */ siteRenamedPayload?: SiteRenamed; /** Emitted when meta site was permanently deleted. */ hardDeleted?: SiteHardDeleted; /** Emitted on a namespace change. */ namespaceChanged?: NamespaceChanged; /** Emitted when Studio is attached. */ studioAssigned?: StudioAssigned; /** Emitted when Studio is detached. */ studioUnassigned?: StudioUnassigned; } export interface Asset { /** An application definition id (app_id in dev-center). For legacy reasons may be UUID or a string (from Java Enum). */ appDefId?: string; /** An instance id. For legacy reasons may be UUID or a string. */ instanceId?: string; /** An application state. */ state?: State; } export declare enum State { UNKNOWN = "UNKNOWN", ENABLED = "ENABLED", DISABLED = "DISABLED", PENDING = "PENDING", DEMO = "DEMO" } export interface SiteCreated { /** A template identifier (empty if not created from a template). */ originTemplateId?: string; /** An account id of the owner. */ ownerId?: string; /** A context in which meta site was created. */ context?: SiteCreatedContext; /** * A meta site id from which this site was created. * * In case of a creation from a template it's a template id. * In case of a site duplication ("Save As" in dashboard or duplicate in UM) it's an id of a source site. */ originMetaSiteId?: string | null; /** A meta site name (URL slug). */ siteName?: string; /** A namespace. */ namespace?: Namespace; } export declare enum SiteCreatedContext { /** A valid option, we don't expose all reasons why site might be created. */ OTHER = "OTHER", /** A meta site was created from template. */ FROM_TEMPLATE = "FROM_TEMPLATE", /** A meta site was created by copying of the transfferred meta site. */ DUPLICATE_BY_SITE_TRANSFER = "DUPLICATE_BY_SITE_TRANSFER", /** A copy of existing meta site. */ DUPLICATE = "DUPLICATE", /** A meta site was created as a transfferred site (copy of the original), old flow, should die soon. */ OLD_SITE_TRANSFER = "OLD_SITE_TRANSFER", /** deprecated A meta site was created for Flash editor. */ FLASH = "FLASH" } export declare enum Namespace { UNKNOWN_NAMESPACE = "UNKNOWN_NAMESPACE", /** Default namespace for UGC sites. MetaSites with this namespace will be shown in a user's site list by default. */ WIX = "WIX", /** ShoutOut stand alone product. These are siteless (no actual Wix site, no HtmlWeb). MetaSites with this namespace will *not* be shown in a user's site list by default. */ SHOUT_OUT = "SHOUT_OUT", /** MetaSites created by the Albums product, they appear as part of the Albums app. MetaSites with this namespace will *not* be shown in a user's site list by default. */ ALBUMS = "ALBUMS", /** Part of the WixStores migration flow, a user tries to migrate and gets this site to view and if the user likes it then stores removes this namespace and deletes the old site with the old stores. MetaSites with this namespace will *not* be shown in a user's site list by default. */ WIX_STORES_TEST_DRIVE = "WIX_STORES_TEST_DRIVE", /** Hotels standalone (siteless). MetaSites with this namespace will *not* be shown in a user's site list by default. */ HOTELS = "HOTELS", /** Clubs siteless MetaSites, a club without a wix website. MetaSites with this namespace will *not* be shown in a user's site list by default. */ CLUBS = "CLUBS", /** A partially created ADI website. MetaSites with this namespace will *not* be shown in a user's site list by default. */ ONBOARDING_DRAFT = "ONBOARDING_DRAFT", /** AppBuilder for AppStudio / shmite (c). MetaSites with this namespace will *not* be shown in a user's site list by default. */ DEV_SITE = "DEV_SITE", /** LogoMaker websites offered to the user after logo purchase. MetaSites with this namespace will *not* be shown in a user's site list by default. */ LOGOS = "LOGOS", /** VideoMaker websites offered to the user after video purchase. MetaSites with this namespace will *not* be shown in a user's site list by default. */ VIDEO_MAKER = "VIDEO_MAKER", /** MetaSites with this namespace will *not* be shown in a user's site list by default. */ PARTNER_DASHBOARD = "PARTNER_DASHBOARD", /** MetaSites with this namespace will *not* be shown in a user's site list by default. */ DEV_CENTER_COMPANY = "DEV_CENTER_COMPANY", /** * A draft created by HTML editor on open. Upon "first save" it will be moved to be of WIX domain. * * Meta site with this namespace will *not* be shown in a user's site list by default. */ HTML_DRAFT = "HTML_DRAFT", /** * the user-journey for Fitness users who want to start from managing their business instead of designing their website. * Will be accessible from Site List and will not have a website app. * Once the user attaches a site, the site will become a regular wixsite. */ SITELESS_BUSINESS = "SITELESS_BUSINESS", /** Belongs to "strategic products" company. Supports new product in the creator's economy space. */ CREATOR_ECONOMY = "CREATOR_ECONOMY", /** It is to be used in the Business First efforts. */ DASHBOARD_FIRST = "DASHBOARD_FIRST", /** Bookings business flow with no site. */ ANYWHERE = "ANYWHERE", /** Namespace for Headless Backoffice with no editor */ HEADLESS = "HEADLESS", /** * Namespace for master site that will exist in parent account that will be referenced by subaccounts * The site will be used for account level CSM feature for enterprise */ ACCOUNT_MASTER_CMS = "ACCOUNT_MASTER_CMS", /** Rise.ai Siteless account management for Gift Cards and Store Credit. */ RISE = "RISE", /** * As part of the branded app new funnel, users now can create a meta site that will be branded app first. * There's a blank site behind the scene but it's blank). * The Mobile company will be the owner of this namespace. */ BRANDED_FIRST = "BRANDED_FIRST", /** Nownia.com Siteless account management for Ai Scheduling Assistant. */ NOWNIA = "NOWNIA", /** * UGC Templates are templates that are created by users for personal use and to sale to other users. * The Partners company owns this namespace. */ UGC_TEMPLATE = "UGC_TEMPLATE", /** Codux Headless Sites */ CODUX = "CODUX", /** Bobb - AI Design Creator. */ MEDIA_DESIGN_CREATOR = "MEDIA_DESIGN_CREATOR" } /** Site transferred to another user. */ export interface SiteTransferred { /** A previous owner id (user that transfers meta site). */ oldOwnerId?: string; /** A new owner id (user that accepts meta site). */ newOwnerId?: string; } /** Soft deletion of the meta site. Could be restored. */ export interface SiteDeleted { /** A deletion context. */ deleteContext?: DeleteContext; } export interface DeleteContext { /** When the meta site was deleted. */ dateDeleted?: Date | null; /** A status. */ deleteStatus?: DeleteStatus; /** A reason (flow). */ deleteOrigin?: string; /** A service that deleted it. */ initiatorId?: string | null; } export declare enum DeleteStatus { UNKNOWN = "UNKNOWN", TRASH = "TRASH", DELETED = "DELETED", PENDING_PURGE = "PENDING_PURGE" } /** Restoration of the meta site. */ export interface SiteUndeleted { } /** First publish of a meta site. Or subsequent publish after unpublish. */ export interface SitePublished { } export interface SiteUnpublished { /** A list of URLs previously associated with the meta site. */ urls?: string[]; } export interface SiteMarkedAsTemplate { } export interface SiteMarkedAsWixSite { } /** * Represents a service provisioned a site. * * Note on `origin_instance_id`: * There is no guarantee that you will be able to find a meta site using `origin_instance_id`. * This is because of the following scenario: * * Imagine you have a template where a third-party application (TPA) includes some stub data, * such as a product catalog. When you create a site from this template, you inherit this * default product catalog. However, if the template's product catalog is modified, * your site will retain the catalog as it was at the time of site creation. This ensures that * your site remains consistent with what you initially received and does not include any * changes made to the original template afterward. * To ensure this, the TPA on the template gets a new instance_id. */ export interface ServiceProvisioned { /** Either UUID or EmbeddedServiceType. */ appDefId?: string; /** Not only UUID. Something here could be something weird. */ instanceId?: string; /** An instance id from which this instance is originated. */ originInstanceId?: string; /** A version. */ version?: string | null; /** The origin meta site id */ originMetaSiteId?: string | null; } export interface ServiceRemoved { /** Either UUID or EmbeddedServiceType. */ appDefId?: string; /** Not only UUID. Something here could be something weird. */ instanceId?: string; /** A version. */ version?: string | null; } /** Rename of the site. Meaning, free public url has been changed as well. */ export interface SiteRenamed { /** A new meta site name (URL slug). */ newSiteName?: string; /** A previous meta site name (URL slug). */ oldSiteName?: string; } /** * Hard deletion of the meta site. * * Could not be restored. Therefore it's desirable to cleanup data. */ export interface SiteHardDeleted { /** A deletion context. */ deleteContext?: DeleteContext; } export interface NamespaceChanged { /** A previous namespace. */ oldNamespace?: Namespace; /** A new namespace. */ newNamespace?: Namespace; } /** Assigned Studio editor */ export interface StudioAssigned { } /** Unassigned Studio editor */ export interface StudioUnassigned { } export interface Empty { } export interface DomainEvent extends DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; /** * Unique event ID. * Allows clients to ignore duplicate webhooks. */ id?: string; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** ID of the entity associated with the event. */ entityId?: string; /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */ eventTime?: Date | null; /** * Whether the event was triggered as a result of a privacy regulation application * (for example, GDPR). */ triggeredByAnonymizeRequest?: boolean | null; /** If present, indicates the action that triggered the event. */ originatedFrom?: string | null; /** * A sequence number defining the order of updates to the underlying entity. * For example, given that some entity was updated at 16:00 and than again at 16:01, * it is guaranteed that the sequence number of the second update is strictly higher than the first. * As the consumer, you can use this value to ensure that you handle messages in the correct order. * To do so, you will need to persist this number on your end, and compare the sequence number from the * message against the one you have stored. Given that the stored number is higher, you should ignore the message. */ entityEventSequence?: string | null; } /** @oneof */ export interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; } export interface EntityCreatedEvent { entityAsJson?: string; /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */ restoreInfo?: RestoreInfo; } export interface RestoreInfo { deletedDate?: Date | null; } export interface EntityUpdatedEvent { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; } export interface EntityDeletedEvent { /** Entity that was deleted */ deletedEntityAsJson?: string | null; } export interface ActionEvent { bodyAsJson?: string; } export interface MessageEnvelope { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; } export interface IdentificationData extends IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; /** @readonly */ identityType?: WebhookIdentityType; } /** @oneof */ export interface IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; } export declare enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } interface SchemaKeyNonNullableFields { appId: string; entityType: string; scope: SchemaScope; } interface SchemaNonNullableFields { key?: SchemaKeyNonNullableFields; } export interface CreateSchemaResponseNonNullableFields { schema?: SchemaNonNullableFields; } export interface GetSchemaResponseNonNullableFields { schema?: SchemaNonNullableFields; } export interface GetSchemaByKeyResponseNonNullableFields { schema?: SchemaNonNullableFields; } export interface UpdateSchemaResponseNonNullableFields { schema?: SchemaNonNullableFields; } export interface QuerySchemasResponseNonNullableFields { schemas: SchemaNonNullableFields[]; } export interface ListSiteSchemasResponseNonNullableFields { schemas: SchemaNonNullableFields[]; } export {};