whatsapp

package
v3.4.1 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Channel

type Channel struct {
	ReqHandler internal.HTTPHandler
}

func (*Channel) CreateTemplate

func (wap *Channel) CreateTemplate(
	ctx context.Context,
	sender string,
	template models.TemplateCreate,
) (resp models.CreateWATemplateResponse, respDetails models.ResponseDetails, err error)

func (*Channel) DeleteTemplate

func (wap *Channel) DeleteTemplate(
	ctx context.Context,
	sender string,
	templateName string,
) (respDetails models.ResponseDetails, err error)

func (*Channel) GetTemplates

func (wap *Channel) GetTemplates(
	ctx context.Context,
	sender string,
) (resp models.GetWATemplatesResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendAudio

func (wap *Channel) SendAudio(
	ctx context.Context,
	msg models.WAAudioMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendContact

func (wap *Channel) SendContact(
	ctx context.Context,
	msg models.WAContactMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendDocument

func (wap *Channel) SendDocument(
	ctx context.Context,
	msg models.WADocumentMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendImage

func (wap *Channel) SendImage(
	ctx context.Context,
	msg models.WAImageMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveButtons

func (wap *Channel) SendInteractiveButtons(
	ctx context.Context,
	msg models.WAInteractiveButtonsMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveList

func (wap *Channel) SendInteractiveList(
	ctx context.Context,
	msg models.WAInteractiveListMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveMultiproduct

func (wap *Channel) SendInteractiveMultiproduct(
	ctx context.Context,
	msg models.WAInteractiveMultiproductMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveProduct

func (wap *Channel) SendInteractiveProduct(
	ctx context.Context,
	msg models.WAInteractiveProductMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendLocation

func (wap *Channel) SendLocation(
	ctx context.Context,
	msg models.WALocationMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendSticker

func (wap *Channel) SendSticker(
	ctx context.Context,
	msg models.WAStickerMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendTemplate

func (wap *Channel) SendTemplate(
	ctx context.Context,
	messages models.WATemplateMsgs,
) (msgResp models.BulkWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendText

func (wap *Channel) SendText(
	ctx context.Context,
	msg models.WATextMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendVideo

func (wap *Channel) SendVideo(
	ctx context.Context,
	msg models.WAVideoMsg,
) (msgResp models.SendWAMsgResponse, respDetails models.ResponseDetails, err error)

type WhatsApp

type WhatsApp interface {
	SendTemplate(context.Context, models.WATemplateMsgs) (models.BulkWAMsgResponse, models.ResponseDetails, error)
	SendText(context.Context, models.WATextMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendDocument(context.Context, models.WADocumentMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendImage(context.Context, models.WAImageMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendAudio(context.Context, models.WAAudioMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendVideo(context.Context, models.WAVideoMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendSticker(context.Context, models.WAStickerMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendLocation(context.Context, models.WALocationMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendContact(context.Context, models.WAContactMsg) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendInteractiveButtons(context.Context, models.WAInteractiveButtonsMsg,
	) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendInteractiveList(context.Context, models.WAInteractiveListMsg,
	) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendInteractiveProduct(context.Context, models.WAInteractiveProductMsg,
	) (models.SendWAMsgResponse, models.ResponseDetails, error)
	SendInteractiveMultiproduct(context.Context, models.WAInteractiveMultiproductMsg,
	) (models.SendWAMsgResponse, models.ResponseDetails, error)
	GetTemplates(context.Context, string) (models.GetWATemplatesResponse, models.ResponseDetails, error)
	CreateTemplate(context.Context, string, models.TemplateCreate,
	) (models.CreateWATemplateResponse, models.ResponseDetails, error)
	DeleteTemplate(context.Context, string, string,
	) (models.ResponseDetails, error)
}

WhatsApp provides methods to interact with the Infobip WhatsApp API. WhatsApp API docs: https://www.infobip.com/docs/api#channels/whatsapp

Jump to

Keyboard shortcuts

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