This project is not covered by Drupal’s security advisory policy.
AWS SNS Entity Publish is a module to publish any entities like (node, paragraphs, media, etc..) as JSON data to Amazon SNS Topic.
How to use. ( Drupal 9 & 10 )
- Download module and enable.
- Make sure aws-sdk-php is installed.
- It is recommended to install this module using composer. So that it will download all dependencies altogether.
This module will provide a feature to check the test connection after configuring the endpoints in the backend by visiting this URL : http://xxxxxxxxxx/admin/config/aws-sns-entity-publish/test
Use module by service.
use Drupal\Core\Entity\EntityInterface;
/**
* Implements hook_entity_update().
*/
function aws_sns_entity_publish_entity_update(EntityInterface $entity) {
$config = \Drupal::service('config.factory')->get('aws_sns_entity_publish.awsconfig');
$bundle_name = $entity->bundle();
if ($bundle_name == 'YOUR_CONTENT_TYPE_NAME') {
$asp_service = \Drupal::service('aws_sns_entity_publish.asp_services');
// serialize the entity response.
$payload = \Drupal::service('serializer')->serialize($entity, 'json');
$subject = t('Updating @bundleName content.', ['@bundleName' => $bundle_name]);
$topic = $config->get('aws_sns_default_topic_arn');
$asp_service->entityPublishToAwsSns($subject, $payload, $topic);
}
}
For More Information: Please refer the README.md
Supporting organizations:
Project information
- Project categories: Integrations
60 sites report using this module
- Created by subramani.msc2011 on , updated
This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.
Releases
1.0.0-alpha5
released 3 November 2023
Works with Drupal: ^9.5 || ^10
Install:
Development version: 1.0.x-dev updated 3 Nov 2023 at 14:08 UTC




