---
title: "fswa_import_extra_root_keys — Filter Hook"
description: "Whitelist additional top-level keys so a Build import document passes strict validation."
url: "https://wpwebhooks.org/docs/fswa-import-extra-root-keys/"
---

[WP Webhooks](https://wpwebhooks.org/) / [Docs](https://wpwebhooks.org/docs/) / fswa\_import\_extra\_root\_keys

Filter since v2.4.0

# fswa\_import\_extra\_root\_keys

Whitelist additional top-level keys so a Build import document passes strict validation.

/ Signature

```
apply_filters( 'fswa_import_extra_root_keys', $keys )
```

/ When it fires

The importer validates every document against a strict schema and rejects unknown root keys. Return extra key names here when a companion feature attaches its own top-level block on export and needs it tolerated on import.

/ Parameters

| Name | In | Type | Req | Description |
| --- | --- | --- | --- | --- |
| $keys | param | string\[\] | yes | Extra root-level keys to tolerate (defaults to an empty array). |

/ Returns

`string[]` The list of extra root keys the importer should accept instead of rejecting the document.

/ Examples

Tolerate a custom provenance block on import

```
add_filter( 'fswa_import_extra_root_keys', function ( $keys ) {
    $keys[] = 'exported_from';
    return $keys;
} );
```

/ Related

[Import & Export](https://wpwebhooks.org/docs/import-export/)[fswa\_export\_doc](https://wpwebhooks.org/docs/fswa-export-doc/)[fswa\_import\_trigger](https://wpwebhooks.org/docs/fswa-import-trigger/)

/Ready

## Your next automation is  
one sentence away.

[Install Plugin→](https://wordpress.org/plugins/flowsystems-webhook-actions/) [See the Plugin →](https://wpwebhooks.org/wordpress-webhook-plugin/)

$ wp plugin install flowsystems-webhook-actions --activate

## Structured data

```json
{"@context":"https://schema.org","@type":"TechArticle","name":"fswa_import_extra_root_keys — Filter Hook — Webhook Actions Docs","description":"Whitelist additional top-level keys so a Build import document passes strict validation.","url":"https://wpwebhooks.org/docs/fswa-import-extra-root-keys/","isPartOf":{"@type":"WebSite","name":"WP Webhooks","url":"https://wpwebhooks.org"},"about":{"@type":"SoftwareApplication","name":"Webhook Actions","applicationCategory":"WordPress Plugin"}}
```
