> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # ListDataExtensionSchemas # Package: dataExtensionSchema # Namespace: DataExtensionSchemaService # Method link: https://dev.wix.com/docs/api-reference/business-management/data-extension-schema/list-data-extension-schemas.md ## Permission Scopes: Read Data Extensions Schemas: SCOPE.DATAEXTENSIONS.READ-SCHEMAS ## Introduction Retrieves a list of global and user-defined data extension schemas for a given FQDN. --- ## REST API ### Schema ``` Method: listDataExtensionSchemas Description: Retrieves a list of global and user-defined data extension schemas for a given FQDN. URL: https://www.wixapis.com/v1/schemas Method: GET # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: fqdn Method parameters: query param name: extensionPoints | type: array | description: Extension points within the given entity. query param name: fields | type: array | description: Additional fields that are hidden by default. For example, fields with `"x-wix-archived": true`. - enum: - UNKNOWN_REQUESTED_FIELD: Undefined requested field. - ARCHIVED: Returns `x-wix-archived` fields in `DataExtensionSchema.json_schema`. query param name: fqdn | type: fqdn | description: [Fully qualified domain name](https://dev.wix.com/docs/rest/articles/getting-started/fqdns.md). | required: true query param name: namespaces | type: array | description: Namespaces within the given entity. Return type: ListDataExtensionSchemasResponse - name: dataExtensionSchemas | type: array | description: Requested schemas. - name: id | type: string | description: Schema GUID. - name: fqdn | type: string | description: FQDN of the entity this schema extends. Use a wildcard (`*`) in place of the version number, for example `wix.ecom.*.order`. See [Supported objects](https://dev.wix.com/docs/api-reference/business-management/data-extension-schema/introduction.md#supported-objects) for valid FQDNs. - name: namespace | type: string | description: Namespace for this schema. For example, an app creating schemas might use their app name as a namespace. When a site owner creates a user-defined schema, the namespace is: `_user_fields`. - name: jsonSchema | type: object | description: Schema definition in [JSON schema format](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/the-json-schema.md) with the following [vocab](https://docs.json-everything.net/schema/vocabs/) extension: ``` { "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://wixapis.com/v1/json-schema/extensions", "$vocabulary": { "https://wixapis.com/v1/json-schema/extensions/vocab/data-extensions": true }, "$dynamicAnchor": "meta", "title": "Wix' data-extensions vocabulary meta schema", "type": [ "object", "boolean" ], "properties": { "x-wix-permissions": { "type": "object", "description": "list of identity types that are allowed reading schema properties", "properties": { "read": { "type": "array", "items": { "type": "string", "enum": [ "apps", "owning-app", "users", "users-of-users" ] } }, "write": { "type": "array", "items": { "type": "string", "enum": [ "apps", "owning-app", "users", "users-of-users" ] } } } }, "x-wix-display": { "type": "object", "description": "field display properties", "schema": { "properties": { "placeholder": { "type": "string", "maxLength": 255, "description": "placeholder text for input fields" }, "label": { "type": "string", "maxLength": 255, "description": "label of the input fields" }, "hint": { "type": "string", "maxLength": 255, "description": "a short explanation that appears next to the input field" } } } } } } ``` - name: updatedDate | type: string | description: Date and time the schema was last updated. - name: createdDate | type: string | description: Date and time the schema was created. - name: revision | type: string | description: 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. - name: maxLimitBytes | type: integer | description: Maximum allowed schema size in bytes. - name: currentSizeBytes | type: integer | description: Current schema size in bytes. ``` ### Examples ### ListDataExtensionSchemas ```curl ~~~cURL curl -X GET \ 'https://www.wixapis.com/schema-service/v1/schemas?fqdn=wix.ecom.%2A.order' \ -H 'Content-type: application/json' \ -H 'Authorization: ' ~~~ ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.dataExtensionSchema.DataExtensionSchemaService.listDataExtensionSchemas(fqdn, options) Description: Retrieves a list of global and user-defined data extension schemas for a given FQDN. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: fqdn Method parameters: param name: fqdn | type: string | description: [Fully qualified domain name](https://dev.wix.com/docs/rest/articles/getting-started/fqdns.md). | required: true param name: options | type: ListDataExtensionSchemasOptions none - name: namespaces | type: array | description: Namespaces within the given entity. - name: fields | type: array | description: Additional fields that are hidden by default. For example, fields with `"x-wix-archived": true`. - enum: - UNKNOWN_REQUESTED_FIELD: Undefined requested field. - ARCHIVED: Returns `x-wix-archived` fields in `DataExtensionSchema.json_schema`. - name: extensionPoints | type: array | description: Extension points within the given entity. Return type: PROMISE - name: dataExtensionSchemas | type: array | description: Requested schemas. - name: _id | type: string | description: Schema GUID. - name: fqdn | type: string | description: FQDN of the entity this schema extends. Use a wildcard (`*`) in place of the version number, for example `wix.ecom.*.order`. See [Supported objects](https://dev.wix.com/docs/api-reference/business-management/data-extension-schema/introduction.md#supported-objects) for valid FQDNs. - name: namespace | type: string | description: Namespace for this schema. For example, an app creating schemas might use their app name as a namespace. When a site owner creates a user-defined schema, the namespace is: `_user_fields`. - name: jsonSchema | type: object | description: Schema definition in [JSON schema format](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/the-json-schema.md) with the following [vocab](https://docs.json-everything.net/schema/vocabs/) extension: ``` { "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://wixapis.com/v1/json-schema/extensions", "$vocabulary": { "https://wixapis.com/v1/json-schema/extensions/vocab/data-extensions": true }, "$dynamicAnchor": "meta", "title": "Wix' data-extensions vocabulary meta schema", "type": [ "object", "boolean" ], "properties": { "x-wix-permissions": { "type": "object", "description": "list of identity types that are allowed reading schema properties", "properties": { "read": { "type": "array", "items": { "type": "string", "enum": [ "apps", "owning-app", "users", "users-of-users" ] } }, "write": { "type": "array", "items": { "type": "string", "enum": [ "apps", "owning-app", "users", "users-of-users" ] } } } }, "x-wix-display": { "type": "object", "description": "field display properties", "schema": { "properties": { "placeholder": { "type": "string", "maxLength": 255, "description": "placeholder text for input fields" }, "label": { "type": "string", "maxLength": 255, "description": "label of the input fields" }, "hint": { "type": "string", "maxLength": 255, "description": "a short explanation that appears next to the input field" } } } } } } ``` - name: _updatedDate | type: Date | description: Date and time the schema was last updated. - name: _createdDate | type: Date | description: Date and time the schema was created. - name: revision | type: string | description: 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. - name: maxLimitBytes | type: integer | description: Maximum allowed schema size in bytes. - name: currentSizeBytes | type: integer | description: Current schema size in bytes. ``` ### Examples ### listDataExtensionSchemas ```javascript import { schemas } from '@wix/data-extension-schema'; async function listDataExtensionSchemas(fqdn,options) { const response = await schemas.listDataExtensionSchemas(fqdn,options); }; ``` ### listDataExtensionSchemas (with elevated permissions) ```javascript import { schemas } from '@wix/data-extension-schema'; import { auth } from '@wix/essentials'; async function myListDataExtensionSchemasMethod(fqdn,options) { const elevatedListDataExtensionSchemas = auth.elevate(schemas.listDataExtensionSchemas); const response = await elevatedListDataExtensionSchemas(fqdn,options); } ``` ### listDataExtensionSchemas (self-hosted) Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md). ```javascript import { createClient } from '@wix/sdk'; import { schemas } from '@wix/data-extension-schema'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { schemas }, // Include the auth strategy and host as relevant }); async function listDataExtensionSchemas(fqdn,options) { const response = await myWixClient.schemas.listDataExtensionSchemas(fqdn,options); }; ``` ---