Experimental project
This is a sandbox project, which contains experimental code for developer use only.
Yext Entity Sync seeks to aid in synchronizing drupal entities with a Yext Knowledge Graph. Whenever an entity in Drupal is created/updated/deleted, Yext Entity Sync will synchronize the change in the corresponding Yext environment. Due to the highly customizable nature of Drupal and Yext, users of this module will have to implement their own mappings (how to do this is covered below).
Features
On save/edit/delete, synchronize the affected entity within your Yext environment. For example, editing the office hours of a location within Drupal and saving the entity will then update the hours of the location entity within your Yext environment.
Post-Installation
How does this module actually work once I install it? Should I go to a config page? Should I look for a new content type? Should I go and manage my text formats? Provide an overview of the configuration process and any other special considerations for the module.
After installing, a Yext app key(instructions for creating an app here: https://hitchhikers.yext.com/guides/create-an-app/01-create-an-app/) will need to be added to settings[.local].php like so:
// settings.local.php
$settings['yext_key'] = 'your-key';
Then mappings will need to be added so the module knows how to translate a drupal entity into a Yext entity.
to add custom mappings, make a custom module with custom maps that implement `MapInterface` and add them to the `services.yml` with the tag `{ name: yext_entity_sync.map }` e.g. if the custom module is named `yext_enitity_sync_maps` then a custom map could be defined like so:
yml
# yext_entity_sync_maps/yext_entity_sync_maps.services.yml
services:
yext_entity_sync_maps.map.provider:
class: Drupal\yext_entity_sync_maps\Maps\ProviderMap
tags:
- { name: yext_entity_sync.map }
Then `ProviderMap.php` might look like so:
<?php
// yext_entity_sync_maps/src/Maps/ProviderMap.php
namespace Drupal\yext_entity_sync_maps\Maps;
use Drupal\yext_entity_sync\Interfaces\MapInterface;
class ProviderMap implements MapInterface {
// your code here
}
/>
Don't forget to enable your module, e.g. drush en yext_entity_sync_maps
Additional Requirements
This module is dependent on the drupal/hook_post_action module in order to run the synchronizations after an entity has been created/updated/deleted.
Project information
Seeking co-maintainer(s)
Maintainers are looking for help reviewing issues.Maintenance fixes only
Considered feature-complete by its maintainers.- Project categories: Automation
- Created by modea_chase on , updated