whatsapp

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2022 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.TemplateResponse, respDetails models.ResponseDetails, err error)

func (*Channel) GetTemplates

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

func (*Channel) SendAudioMsg

func (wap *Channel) SendAudioMsg(
	ctx context.Context,
	msg models.AudioMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendContactMsg

func (wap *Channel) SendContactMsg(
	ctx context.Context,
	msg models.ContactMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendDocumentMsg

func (wap *Channel) SendDocumentMsg(
	ctx context.Context,
	msg models.DocumentMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendImageMsg

func (wap *Channel) SendImageMsg(
	ctx context.Context,
	msg models.ImageMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveButtonsMsg

func (wap *Channel) SendInteractiveButtonsMsg(
	ctx context.Context,
	msg models.InteractiveButtonsMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveListMsg

func (wap *Channel) SendInteractiveListMsg(
	ctx context.Context,
	msg models.InteractiveListMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveMultiproductMsg

func (wap *Channel) SendInteractiveMultiproductMsg(
	ctx context.Context,
	msg models.InteractiveMultiproductMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendInteractiveProductMsg

func (wap *Channel) SendInteractiveProductMsg(
	ctx context.Context,
	msg models.InteractiveProductMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendLocationMsg

func (wap *Channel) SendLocationMsg(
	ctx context.Context,
	msg models.LocationMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendStickerMsg

func (wap *Channel) SendStickerMsg(
	ctx context.Context,
	msg models.StickerMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendTemplateMsgs

func (wap *Channel) SendTemplateMsgs(
	ctx context.Context,
	messages models.TemplateMsgs,
) (msgResp models.BulkMsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendTextMsg

func (wap *Channel) SendTextMsg(
	ctx context.Context,
	msg models.TextMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

func (*Channel) SendVideoMsg

func (wap *Channel) SendVideoMsg(
	ctx context.Context,
	msg models.VideoMsg,
) (msgResp models.MsgResponse, respDetails models.ResponseDetails, err error)

type WhatsApp

type WhatsApp interface {
	SendTemplateMsgs(context.Context, models.TemplateMsgs) (models.BulkMsgResponse, models.ResponseDetails, error)
	SendTextMsg(context.Context, models.TextMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendDocumentMsg(context.Context, models.DocumentMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendImageMsg(context.Context, models.ImageMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendAudioMsg(context.Context, models.AudioMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendVideoMsg(context.Context, models.VideoMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendStickerMsg(context.Context, models.StickerMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendLocationMsg(context.Context, models.LocationMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendContactMsg(context.Context, models.ContactMsg) (models.MsgResponse, models.ResponseDetails, error)
	SendInteractiveButtonsMsg(context.Context, models.InteractiveButtonsMsg,
	) (models.MsgResponse, models.ResponseDetails, error)
	SendInteractiveListMsg(context.Context, models.InteractiveListMsg,
	) (models.MsgResponse, models.ResponseDetails, error)
	SendInteractiveProductMsg(context.Context, models.InteractiveProductMsg,
	) (models.MsgResponse, models.ResponseDetails, error)
	SendInteractiveMultiproductMsg(context.Context, models.InteractiveMultiproductMsg,
	) (models.MsgResponse, models.ResponseDetails, error)
	GetTemplates(context.Context, string) (models.TemplatesResponse, models.ResponseDetails, error)
	CreateTemplate(context.Context, string, models.TemplateCreate) (models.TemplateResponse, 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