--- title: Web source JSON modification slug: mc1f0219 canonical_url: https://docs.coveo.com/en/mc1f0219/ collection: index-content source_format: adoc --- # Web source JSON modification Many [source](https://docs.coveo.com/en/246/) configuration parameters can be set through the user interface. Others, such as rarely used or new parameters, must be configured in the **Edit configuration with JSON** panel. To access this panel from the [**Sources**](https://platform.cloud.coveo.com/admin/#/orgid/content/sources/) ([platform-ca](https://platform-ca.cloud.coveo.com/admin/#/orgid/content/sources/) | [platform-eu](https://platform-eu.cloud.coveo.com/admin/#/orgid/content/sources/) | [platform-au](https://platform-au.cloud.coveo.com/admin/#/orgid/content/sources/)) page, click the source, and then click **Edit configuration with JSON** in the **More** menu. This article explains how to configure Web source parameters, whether they're already listed in the JSON or not. ## Configuring listed and unlisted parameters [float-group] -- ![Changing a parameter value in the source JSON configuration | Coveo](https://docs.coveo.com/en/assets/images/index-content/changing-parameter-values.gif) If the parameter you want to change is already listed in the `parameters` section of the source JSON configuration, just modify its `value` in the JSON configuration. If the parameter isn't listed in the `parameters` section, copy the entire parameter example object from the [Reference](#reference) section below and paste it into that section. Then, update the `value` in the JSON configuration, if necessary. -- > **Important** > > If a parameter has a `value` attribute that contains sensitive information, set the `sensitive` attribute to `true`. > Otherwise, the value will appear in clear text in the JSON configuration. > **Tip** > > Document the changes you make to the source JSON configuration in the **Comments** area below the JSON configuration. > This ensures that you can easily revert to a previous configuration if needed. ## Reference This section provides information on the Web source parameters that you can only modify through the JSON configuration. If a JSON configuration parameter isn't documented in this article, configure it through the source edition panel instead. ### `AdditionalHeaders` (Object | Null) Specifies a map of HTTP headers in JSON format to be sent with every HTTP request. The value must be a valid JSON map in the format: `{\"header1\": \"value1\", \"header2\": \"value2\", ... }`. The value is `null` by default. Don't use the `AdditionalHeaders` parameter to send the `Authorization` header. This will generate an error as soon as you start an indexing action. Avoid using the `AdditionalHeaders` parameter to submit sensitive information, such as API keys or authentication tokens — doing so is bad practice. > **Important** > > When **Execute JavaScript on pages** is enabled on the source, adding manual cookies significantly impacts indexing performance. **Example** ```json "AdditionalHeaders": { "sensitive": true, "value": "{\"X-CSRF-Token\": \"6b609652ef8e448eb6de270139d489c3\"}" } ``` ### `AllowedDeletionPercentage` (Integer) This parameter specifies the maximum allowed percentage of [source](https://docs.coveo.com/en/246/) [items](https://docs.coveo.com/en/210/) that can be deleted from the index at the end of a [rescan](https://docs.coveo.com/en/2711/). If the actual percentage of source items to delete exceeds this value, no items are deleted from the index. By default, this parameter is set to `100`, which means that all source items can be deleted. The purpose of this parameter is to prevent accidental mass item deletions. This can occur, for example, because of an improper source configuration or if the content to index was moved. For more information about this parameter and its usage, see [Forbid item deletion based on a percentage condition](https://docs.coveo.com/en/2006#forbid-item-deletion-based-on-a-percentage-condition). **Example** You can set `AllowedDeletionPercentage` to `10` in the JSON configuration of your source, as shown in the snippet below. With this configuration, if Coveo detects that more than 10% of the items are flagged for deletion during a rescan, deletion will be blocked. The status on the [**Sources**](https://platform.cloud.coveo.com/admin/#/orgid/content/sources/) ([platform-ca](https://platform-ca.cloud.coveo.com/admin/#/orgid/content/sources/) | [platform-eu](https://platform-eu.cloud.coveo.com/admin/#/orgid/content/sources/) | [platform-au](https://platform-au.cloud.coveo.com/admin/#/orgid/content/sources/)) page will show your source in error, and the error details will indicate the actual percentage of items that were flagged for deletion versus the allowed percentage (in this case, 10%). ```json "AllowedDeletionPercentage": { "sensitive": false, "value": "10" } ``` ### `ElementsToRemove` (Array of strings) The value is a JSON-encoded array of HTML tag names to remove from the page content before indexing. The default value is `"[\"script\"]"` to prevent JavaScript code from being indexed. **Example** The configuration below removes all ` ``` To index the publisher name value (that is, `BBC News` in this page) in an index field . Set your configuration as follows: ```json "IndexJsonLdMetadata": { "sensitive": false, "value": "true" } ``` . Use the following [mapping rule](https://docs.coveo.com/en/1640#manage-mappings) for your field: `%[jsonld.publisher.name]` > **Notes** > > * JSON-LD metadata is still indexed even when you exclude `