Documentation ¶
Index ¶
- Constants
- type PresentationHandlers
- type PresentationHandlersImpl
- func (p PresentationHandlersImpl) DataDeletionRequestCallback() http.HandlerFunc
- func (p PresentationHandlersImpl) DeleteAction() http.HandlerFunc
- func (p PresentationHandlersImpl) DeleteFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) DeleteMessage() http.HandlerFunc
- func (p PresentationHandlersImpl) DeleteNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) FindUpload() http.HandlerFunc
- func (p PresentationHandlersImpl) GetAction() http.HandlerFunc
- func (p PresentationHandlersImpl) GetFallbackHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) GetFeed() http.HandlerFunc
- func (p PresentationHandlersImpl) GetFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) GetIncomingMessageHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) GetNotificationHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) GetNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) GetTwilioVideoCallbackFunc() http.HandlerFunc
- func (p PresentationHandlersImpl) GoogleCloudPubSubHandler(w http.ResponseWriter, r *http.Request)
- func (p PresentationHandlersImpl) HideFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) HideNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) PhoneNumberVerificationCodeHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) PinFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) PostMessage() http.HandlerFunc
- func (p PresentationHandlersImpl) ProcessEvent() http.HandlerFunc
- func (p PresentationHandlersImpl) PublishAction() http.HandlerFunc
- func (p PresentationHandlersImpl) PublishFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) PublishNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) ResolveDefaultNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) ResolveFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) ResolveNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) SendEmail() http.HandlerFunc
- func (p PresentationHandlersImpl) SendEmailOTP() http.HandlerFunc
- func (p PresentationHandlersImpl) SendNotificationHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) SendOTPHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) SendRetryOTPHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) SendTemporaryPIN() http.HandlerFunc
- func (p PresentationHandlersImpl) SendToMany() http.HandlerFunc
- func (p PresentationHandlersImpl) ShowFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) ShowNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) UnpinFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) UnresolveFeedItem() http.HandlerFunc
- func (p PresentationHandlersImpl) UnresolveNudge() http.HandlerFunc
- func (p PresentationHandlersImpl) UpdateMailgunDeliveryStatus() http.HandlerFunc
- func (p PresentationHandlersImpl) Upload() http.HandlerFunc
- func (p PresentationHandlersImpl) VerifyRetryEmailOTPHandler() http.HandlerFunc
- func (p PresentationHandlersImpl) VerifyRetryOTPHandler() http.HandlerFunc
Constants ¶
const (
// StaticDir is the directory that contains schemata, default images etc
StaticDir = "github.com/savannahghi/engagementcore:/static/"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PresentationHandlers ¶
type PresentationHandlers interface { GoogleCloudPubSubHandler(w http.ResponseWriter, r *http.Request) GetFeed() http.HandlerFunc GetFeedItem() http.HandlerFunc GetNudge() http.HandlerFunc GetAction() http.HandlerFunc PublishFeedItem() http.HandlerFunc DeleteFeedItem() http.HandlerFunc ResolveFeedItem() http.HandlerFunc PinFeedItem() http.HandlerFunc UnpinFeedItem() http.HandlerFunc HideFeedItem() http.HandlerFunc ShowFeedItem() http.HandlerFunc UnresolveFeedItem() http.HandlerFunc PublishNudge() http.HandlerFunc ResolveNudge() http.HandlerFunc ResolveDefaultNudge() http.HandlerFunc UnresolveNudge() http.HandlerFunc HideNudge() http.HandlerFunc ShowNudge() http.HandlerFunc DeleteNudge() http.HandlerFunc PublishAction() http.HandlerFunc DeleteAction() http.HandlerFunc PostMessage() http.HandlerFunc DeleteMessage() http.HandlerFunc ProcessEvent() http.HandlerFunc Upload() http.HandlerFunc FindUpload() http.HandlerFunc SendEmail() http.HandlerFunc SendToMany() http.HandlerFunc GetNotificationHandler() http.HandlerFunc GetIncomingMessageHandler() http.HandlerFunc GetFallbackHandler() http.HandlerFunc PhoneNumberVerificationCodeHandler() http.HandlerFunc SendOTPHandler() http.HandlerFunc SendRetryOTPHandler() http.HandlerFunc VerifyRetryOTPHandler() http.HandlerFunc VerifyRetryEmailOTPHandler() http.HandlerFunc SendNotificationHandler() http.HandlerFunc UpdateMailgunDeliveryStatus() http.HandlerFunc DataDeletionRequestCallback() http.HandlerFunc GetTwilioVideoCallbackFunc() http.HandlerFunc SendTemporaryPIN() http.HandlerFunc SendEmailOTP() http.HandlerFunc }
PresentationHandlers represents all the REST API logic
func NewPresentationHandlers ¶
func NewPresentationHandlers(infrastructure infrastructure.Interactor, usecases usecases.Interactor) PresentationHandlers
NewPresentationHandlers initializes a new rest handlers usecase
type PresentationHandlersImpl ¶
type PresentationHandlersImpl struct {
// contains filtered or unexported fields
}
PresentationHandlersImpl represents the usecase implementation object
func (PresentationHandlersImpl) DataDeletionRequestCallback ¶
func (p PresentationHandlersImpl) DataDeletionRequestCallback() http.HandlerFunc
DataDeletionRequestCallback is a Facebook's data deletion request callback
func (PresentationHandlersImpl) DeleteAction ¶
func (p PresentationHandlersImpl) DeleteAction() http.HandlerFunc
DeleteAction permanently removes an action from a user's feed
func (PresentationHandlersImpl) DeleteFeedItem ¶
func (p PresentationHandlersImpl) DeleteFeedItem() http.HandlerFunc
DeleteFeedItem removes a feed item
func (PresentationHandlersImpl) DeleteMessage ¶
func (p PresentationHandlersImpl) DeleteMessage() http.HandlerFunc
DeleteMessage removes a message from a thread
func (PresentationHandlersImpl) DeleteNudge ¶
func (p PresentationHandlersImpl) DeleteNudge() http.HandlerFunc
DeleteNudge permanently deletes a nudge
func (PresentationHandlersImpl) FindUpload ¶
func (p PresentationHandlersImpl) FindUpload() http.HandlerFunc
FindUpload retrieves an upload by it's ID
func (PresentationHandlersImpl) GetAction ¶
func (p PresentationHandlersImpl) GetAction() http.HandlerFunc
GetAction retrieves a single action
func (PresentationHandlersImpl) GetFallbackHandler ¶
func (p PresentationHandlersImpl) GetFallbackHandler() http.HandlerFunc
GetFallbackHandler returns a handler that processes an Africa's Talking payment notification
func (PresentationHandlersImpl) GetFeed ¶
func (p PresentationHandlersImpl) GetFeed() http.HandlerFunc
GetFeed retrieves and serves a feed
func (PresentationHandlersImpl) GetFeedItem ¶
func (p PresentationHandlersImpl) GetFeedItem() http.HandlerFunc
GetFeedItem retrieves a single feed item
func (PresentationHandlersImpl) GetIncomingMessageHandler ¶
func (p PresentationHandlersImpl) GetIncomingMessageHandler() http.HandlerFunc
GetIncomingMessageHandler returns a handler that processes an Africa's Talking payment notification
func (PresentationHandlersImpl) GetNotificationHandler ¶
func (p PresentationHandlersImpl) GetNotificationHandler() http.HandlerFunc
GetNotificationHandler returns a handler that processes an Africa's Talking payment notification
func (PresentationHandlersImpl) GetNudge ¶
func (p PresentationHandlersImpl) GetNudge() http.HandlerFunc
GetNudge retrieves a single nudge
func (PresentationHandlersImpl) GetTwilioVideoCallbackFunc ¶
func (p PresentationHandlersImpl) GetTwilioVideoCallbackFunc() http.HandlerFunc
GetTwilioVideoCallbackFunc generates a Twilio Video callback handling function.
Twilio sends the data with the "Content-Type" header to “application/x-www-urlencoded”.
func (PresentationHandlersImpl) GoogleCloudPubSubHandler ¶
func (p PresentationHandlersImpl) GoogleCloudPubSubHandler( w http.ResponseWriter, r *http.Request, )
GoogleCloudPubSubHandler receives push messages from Google Cloud Pub-Sub
func (PresentationHandlersImpl) HideFeedItem ¶
func (p PresentationHandlersImpl) HideFeedItem() http.HandlerFunc
HideFeedItem marks a feed item as done
func (PresentationHandlersImpl) HideNudge ¶
func (p PresentationHandlersImpl) HideNudge() http.HandlerFunc
HideNudge marks a nudge as not resolved
func (PresentationHandlersImpl) PhoneNumberVerificationCodeHandler ¶
func (p PresentationHandlersImpl) PhoneNumberVerificationCodeHandler() http.HandlerFunc
PhoneNumberVerificationCodeHandler process ISC request to PhoneNumberVerificationCode
func (PresentationHandlersImpl) PinFeedItem ¶
func (p PresentationHandlersImpl) PinFeedItem() http.HandlerFunc
PinFeedItem marks a feed item as done
func (PresentationHandlersImpl) PostMessage ¶
func (p PresentationHandlersImpl) PostMessage() http.HandlerFunc
PostMessage adds a message to a thread
func (PresentationHandlersImpl) ProcessEvent ¶
func (p PresentationHandlersImpl) ProcessEvent() http.HandlerFunc
ProcessEvent saves an event
func (PresentationHandlersImpl) PublishAction ¶
func (p PresentationHandlersImpl) PublishAction() http.HandlerFunc
PublishAction posts a new action to a user's feed
func (PresentationHandlersImpl) PublishFeedItem ¶
func (p PresentationHandlersImpl) PublishFeedItem() http.HandlerFunc
PublishFeedItem posts a feed item
func (PresentationHandlersImpl) PublishNudge ¶
func (p PresentationHandlersImpl) PublishNudge() http.HandlerFunc
PublishNudge posts a new nudge
func (PresentationHandlersImpl) ResolveDefaultNudge ¶
func (p PresentationHandlersImpl) ResolveDefaultNudge() http.HandlerFunc
ResolveDefaultNudge marks a default nudges as resolved
func (PresentationHandlersImpl) ResolveFeedItem ¶
func (p PresentationHandlersImpl) ResolveFeedItem() http.HandlerFunc
ResolveFeedItem marks a feed item as done
func (PresentationHandlersImpl) ResolveNudge ¶
func (p PresentationHandlersImpl) ResolveNudge() http.HandlerFunc
ResolveNudge marks a nudge as resolved
func (PresentationHandlersImpl) SendEmail ¶
func (p PresentationHandlersImpl) SendEmail() http.HandlerFunc
SendEmail sends the specified email to the recipient(s) specified in `to` and returns the status
func (PresentationHandlersImpl) SendEmailOTP ¶ added in v0.0.36
func (p PresentationHandlersImpl) SendEmailOTP() http.HandlerFunc
SendEmailOTP generates and send an OTP to the email supplied
func (PresentationHandlersImpl) SendNotificationHandler ¶
func (p PresentationHandlersImpl) SendNotificationHandler() http.HandlerFunc
SendNotificationHandler sends a data message to the specified registration tokens.
func (PresentationHandlersImpl) SendOTPHandler ¶
func (p PresentationHandlersImpl) SendOTPHandler() http.HandlerFunc
SendOTPHandler is an isc api that generates and sends an otp to an msisdn
func (PresentationHandlersImpl) SendRetryOTPHandler ¶
func (p PresentationHandlersImpl) SendRetryOTPHandler() http.HandlerFunc
SendRetryOTPHandler is an isc api that generates fallback OTPs when Africa is talking sms fails
func (PresentationHandlersImpl) SendTemporaryPIN ¶
func (p PresentationHandlersImpl) SendTemporaryPIN() http.HandlerFunc
SendTemporaryPIN is a twilio endpoint to send PIN via whatsapp and SMS
func (PresentationHandlersImpl) SendToMany ¶
func (p PresentationHandlersImpl) SendToMany() http.HandlerFunc
SendToMany sends a data message to the specified recipient
func (PresentationHandlersImpl) ShowFeedItem ¶
func (p PresentationHandlersImpl) ShowFeedItem() http.HandlerFunc
ShowFeedItem marks a feed item as done
func (PresentationHandlersImpl) ShowNudge ¶
func (p PresentationHandlersImpl) ShowNudge() http.HandlerFunc
ShowNudge marks a nudge as not resolved
func (PresentationHandlersImpl) UnpinFeedItem ¶
func (p PresentationHandlersImpl) UnpinFeedItem() http.HandlerFunc
UnpinFeedItem marks a feed item as done
func (PresentationHandlersImpl) UnresolveFeedItem ¶
func (p PresentationHandlersImpl) UnresolveFeedItem() http.HandlerFunc
UnresolveFeedItem marks a feed item as not resolved
func (PresentationHandlersImpl) UnresolveNudge ¶
func (p PresentationHandlersImpl) UnresolveNudge() http.HandlerFunc
UnresolveNudge marks a nudge as not resolved
func (PresentationHandlersImpl) UpdateMailgunDeliveryStatus ¶
func (p PresentationHandlersImpl) UpdateMailgunDeliveryStatus() http.HandlerFunc
UpdateMailgunDeliveryStatus gets the status of the sent emails and logs them in the database
func (PresentationHandlersImpl) Upload ¶
func (p PresentationHandlersImpl) Upload() http.HandlerFunc
Upload saves an upload in cloud storage
func (PresentationHandlersImpl) VerifyRetryEmailOTPHandler ¶
func (p PresentationHandlersImpl) VerifyRetryEmailOTPHandler() http.HandlerFunc
VerifyRetryEmailOTPHandler is an isc api that confirms OTPs earlier sent via email.
func (PresentationHandlersImpl) VerifyRetryOTPHandler ¶
func (p PresentationHandlersImpl) VerifyRetryOTPHandler() http.HandlerFunc
VerifyRetryOTPHandler is an isc api that confirms OTPs earlier sent