service

package
v0.0.0-...-a38f904 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2019 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Listener = make(map[string]Subscribe)
)

Global Variables

Functions

func AccessToken

func AccessToken(responseWriter http.ResponseWriter, request *http.Request)

AccessToken Gmail

func Authorization

func Authorization(responseWriter http.ResponseWriter, request *http.Request)

Authorization Gmail

func CreateFilter

func CreateFilter(responseWriter http.ResponseWriter, request *http.Request)

CreateFilter Gmail

func CreateLabel

func CreateLabel(responseWriter http.ResponseWriter, request *http.Request)

CreateLabel Gmail

func DeleteFilter

func DeleteFilter(responseWriter http.ResponseWriter, request *http.Request)

DeleteFilter Gmail

func DeleteLabel

func DeleteLabel(responseWriter http.ResponseWriter, request *http.Request)

DeleteLabel Gmail

func FilterList

func FilterList(responseWriter http.ResponseWriter, request *http.Request)

FilterList Gmail

func Find

func Find(slice []string, val string) (int, bool)

Find string

func GmailRTM

func GmailRTM()

GmailRTM func

func HealthCheck

func HealthCheck(responseWriter http.ResponseWriter, request *http.Request)

HealthCheck Google-Sheets

func ListLabel

func ListLabel(responseWriter http.ResponseWriter, request *http.Request)

ListLabel Gmail

func PatchLabel

func PatchLabel(responseWriter http.ResponseWriter, request *http.Request)

PatchLabel Gmail

func ReceiveMail

func ReceiveMail(responseWriter http.ResponseWriter, request *http.Request)

ReceiveMail Gmail

func RefreshToken

func RefreshToken(responseWriter http.ResponseWriter, request *http.Request)

RefreshToken Gmail

func SendMail

func SendMail(responseWriter http.ResponseWriter, request *http.Request)

SendMail Gmail

Types

type AuthURL

type AuthURL struct {
	URL     string `json:"url"`
	Message string `json:"message"`
}

AuthURL struct

type GmailArgument

type GmailArgument struct {
	UserID                string   `json:"userId"`
	To                    []string `json:"to"`
	Subject               string   `json:"subject,omitempty"`
	Body                  string   `json:"body"`
	AuthorizationCode     string   `json:"authorizationCode"`
	AccessToken           string   `json:"accessToken"`
	TokenObj              Token    `json:"token"`
	LabelName             string   `json:"name"`
	BackgroundColor       string   `json:"backgroundColor,omitempty"`
	TextColor             string   `json:"textColor,omitempty"`
	LabelListVisibility   string   `json:"labelListVisibility,omitempty"`
	MessageListVisibility string   `json:"messageListVisibility,omitempty"`
	LabelID               string   `json:"labelID"`
	Scope                 string   `json:"scope"`
}

GmailArgument struct

type GmailFilter

type GmailFilter struct {
	AccessToken    string `json:"accessToken"`
	UserID         string `json:"userId"`
	FilterID       string `json:"filterID"`
	RemoveLabelID  string `json:"removeLabelId,omitempty"`
	AddLabelID     string `json:"addLabelId,omitempty"`
	ExcludeChats   bool   `json:"excludeChats,omitempty"`
	From           string `json:"from,omitempty"`
	To             string `json:"to,omitempty"`
	Subject        string `json:"subject,omitempty"`
	HasAttachment  bool   `json:"hasAttachment,omitempty"`
	NegatedQuery   string `json:"negatedQuery,omitempty"`
	Query          string `json:"query,omitempty"`
	Size           int64  `json:"size,omitempty"`
	SizeComparison string `json:"sizeComparison,omitempty"`
}

GmailFilter struct

type MailContent

type MailContent struct {
	From    string `json:"from"`
	To      string `json:"to"`
	Subject string `json:"subject"`
	Body    string `json:"body"`
}

MailContent struct

type Message

type Message struct {
	Success    bool   `json:"success"`
	Message    string `json:"message"`
	StatusCode int    `json:"statusCode"`
}

Message struct

type RequestParam

type RequestParam struct {
	AccessToken string `json:"accessToken"`
	UserID      string `json:"UserId"`
}

RequestParam struct

type Subscribe

type Subscribe struct {
	Data      RequestParam `json:"data"`
	Endpoint  string       `json:"endpoint"`
	ID        string       `json:"id"`
	IsTesting bool         `json:"isTesting"`
}

Subscribe struct

type Token

type Token struct {
	AccessToken  string `json:"access_token"`
	RefreshToken string `json:"refresh_token"`
	Expiry       string `json:"expiry"`
	TokenType    string `json:"token_type"`
}

Token struct

Jump to

Keyboard shortcuts

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