> 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 # UpdateExtendedFields # Package: faqApp # Namespace: CategoryService # Method link: https://dev.wix.com/docs/api-reference/business-management/faq-app/category-v2/update-extended-fields.md ## Permission Scopes: Manage FAQ: SCOPE.DC-LABS.MANAGE-FAQ ## Introduction Updates extended fields of a category without incrementing `revision`. --- ## REST API ### Schema ``` Method: updateExtendedFields Description: Updates extended fields of a category without incrementing `revision`. URL: https://www.wixapis.com/faq/v2/categories/{id}/update-extended-fields Method: POST # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: namespace, namespaceData Method parameters: param name: namespace | type: namespace | description: Identifier for the app whose extended fields are being updated. | required: true param name: namespaceData | type: namespaceData | description: Data to update. Structured according to the [schema](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md#json-schema-for-extended-fields) defined when the extended fields were configured. | required: true Return type: UpdateExtendedFieldsResponse - name: category | type: Category | description: Updated category. - name: id | type: string | description: Category GUID. - name: revision | type: string | description: Revision number, which increments by 1 each time the category is updated. To prevent conflicting changes, the current revision must be specified when updating the category. Ignored when creating a category. - name: createdDate | type: string | description: Date and time the category was created. - name: updatedDate | type: string | description: Date and time the category was last updated. - name: title | type: string | description: Category title displayed on a site's Wix FAQ widgets. - name: sortOrder | type: number | description: Order of the category within a site's Wix FAQ dashboard page. Categories with lower sort order values appear first. - name: extendedFields | type: ExtendedFields | description: Custom field data for the `category` object. [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions.md) must be configured in the app dashboard before they can be accessed with API calls. - name: namespaces | type: object | description: Extended field data. Each key corresponds to the namespace of the app that created the extended fields. The value of each key is structured according to the schema defined when the extended fields were configured. You can only access fields for which you have the appropriate permissions. Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md). ``` ### Examples ### UpdateExtendedFields ```curl ~~~cURL curl --request POST \ --url https://www.wixapis.com/faq/v2/categories/a1b2c3d4-e5f6-7890-abcd-ef1234567890/update-extended-fields \ --header 'Authorization: ' \ --header 'Content-Type: application/json' \ --data '{ "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890", "namespace": "custom.category.metadata", "namespace_data": { "priority": "high", "internal_notes": "Customer service priority category" } }' ~~~ ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.faqApp.CategoryService.updateExtendedFields(_id, namespace, options) Description: Updates extended fields of a category without incrementing `revision`. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: _id, namespace, options.namespaceData, options Method parameters: param name: _id | type: string | description: GUID of the entity to update. | required: true param name: namespace | type: string | description: Identifier for the app whose extended fields are being updated. | required: true param name: options | type: UpdateExtendedFieldsOptions none | required: true - name: namespaceData | type: object | description: Data to update. Structured according to the [schema](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md#json-schema-for-extended-fields) defined when the extended fields were configured. | required: true Return type: PROMISE - name: category | type: Category | description: Updated category. - name: _id | type: string | description: Category GUID. - name: revision | type: string | description: Revision number, which increments by 1 each time the category is updated. To prevent conflicting changes, the current revision must be specified when updating the category. Ignored when creating a category. - name: _createdDate | type: Date | description: Date and time the category was created. - name: _updatedDate | type: Date | description: Date and time the category was last updated. - name: title | type: string | description: Category title displayed on a site's Wix FAQ widgets. - name: sortOrder | type: number | description: Order of the category within a site's Wix FAQ dashboard page. Categories with lower sort order values appear first. - name: extendedFields | type: ExtendedFields | description: Custom field data for the `category` object. [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions.md) must be configured in the app dashboard before they can be accessed with API calls. - name: namespaces | type: object | description: Extended field data. Each key corresponds to the namespace of the app that created the extended fields. The value of each key is structured according to the schema defined when the extended fields were configured. You can only access fields for which you have the appropriate permissions. Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md). ``` ### Examples ### updateExtendedFields ```javascript import { category } from '@wix/faq'; async function updateExtendedFields(_id,namespace,options) { const response = await category.updateExtendedFields(_id,namespace,options); }; ``` ### updateExtendedFields (with elevated permissions) ```javascript import { category } from '@wix/faq'; import { auth } from '@wix/essentials'; async function myUpdateExtendedFieldsMethod(_id,namespace,options) { const elevatedUpdateExtendedFields = auth.elevate(category.updateExtendedFields); const response = await elevatedUpdateExtendedFields(_id,namespace,options); } ``` ### updateExtendedFields (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 { category } from '@wix/faq'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { category }, // Include the auth strategy and host as relevant }); async function updateExtendedFields(_id,namespace,options) { const response = await myWixClient.category.updateExtendedFields(_id,namespace,options); }; ``` ---