sns

package
v0.77.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 20, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

README

Simple Notidication Service Service

This service is github.com/aws/aws-sdk-go/service/sqs.SQS proxy

To check all supported method run

    endly -s="aws/sns"

To check method contract run endly -s="aws/sqs" -a=methodName

    endly -s=aws/sns:listSubscriptions
    endly -s=aws/sns:setupPermission
Usage:

Set subscription

endly subscription.yaml authWith=myAWSSecret.json

@subscription.yaml

pipeline:
  setupLambdaSubscription:
    action: aws/sns:setupSubscription
    protocol: lambda
    endpoint: $functionName
    topic: $topic

Set permission

endly set_permission.yaml authWith=myAWSSecret.json

@set_permission.yaml

init:
  '!awsCredentials': $params.authWith

pipeline:
  setupPermission:
    action: aws/sns:setupPermission
    credentials: $awsCredentials
    queue: ms-dataflowStorageMirrorQueue
    AWSAccountId:
      - ${aws.accountID}
    actionName:
      - 'publish'
    everybody: true 

See also Message resource setup and testing

Documentation

Index

Constants

View Source
const (
	//ServiceID aws Simple Notification Service ID.
	ServiceID = "aws/sns"
)

Variables

This section is empty.

Functions

func GetClient

func GetClient(context *endly.Context) (*sns.SNS, error)

GetClient returns sns client from context

func New

func New() endly.Service

New creates a new AWS SNS service.

Types

type SetupPermissionInput

type SetupPermissionInput struct {
	sns.AddPermissionInput
	Everybody bool
	SourceArn string
	Topic     string
}

SetupPermissionInput creates a permission if it does not exists

func (*SetupPermissionInput) Init

func (i *SetupPermissionInput) Init() error

func (*SetupPermissionInput) Validate

func (i *SetupPermissionInput) Validate() error

type SetupSubscriptionInput

type SetupSubscriptionInput struct {
	*sns.SubscribeInput `json:",inline"`
	Topic               *string
}

SetupSubscriptionInput represets setup subscription request

func (*SetupSubscriptionInput) Validate

func (i *SetupSubscriptionInput) Validate() error

SetupSubscriptionInput check if request is valid

type SetupTopicInput

type SetupTopicInput sns.CreateTopicInput

SetupTopicInput represents setup topic request

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL