models

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Audio

type Audio struct {
	ID       string `json:"id"`
	MimeType string `json:"mime_type"`
}

type Button

type Button struct {
	Payload string `json:"payload"`
	Text    string `json:"text"`
}

type ButtonReply

type ButtonReply struct {
	ID    string `json:"id"`
	Title string `json:"title"`
}

type Change

type Change struct {
	Value Value  `json:"value"`
	Field string `json:"field"`
}

type Contact

type Contact struct {
	WaID    string  `json:"wa_id"`
	Profile Profile `json:"profile"`
}

type Context

type Context struct {
	Forwarded           bool             `json:"forwarded"`
	FrequentlyForwarded bool             `json:"frequently_forwarded"`
	From                string           `json:"from"`
	ID                  string           `json:"id"`
	ReferredProduct     *ReferredProduct `json:"referred_product,omitempty"`
}

type Conversation

type Conversation struct {
	ID                  string     `json:"id"`
	Origin              Origin     `json:"origin"`
	ExpirationTimestamp *time.Time `json:"expiration_timestamp,omitempty"`
}

type Document

type Document struct {
	Caption  string `json:"caption,omitempty"`
	Filename string `json:"filename"`
	Sha256   string `json:"sha256"`
	MimeType string `json:"mime_type"`
	ID       string `json:"id"`
}

type Entry

type Entry struct {
	ID      string   `json:"id"`
	Changes []Change `json:"changes"`
}

type Error

type Error struct {
	Code      int        `json:"code"`
	Title     string     `json:"title"`
	Message   string     `json:"message,omitempty"`
	ErrorData *ErrorData `json:"error_data,omitempty"`
}

type ErrorData

type ErrorData struct {
	Details string `json:"details"`
}

type Identity

type Identity struct {
	Acknowledged     bool   `json:"acknowledged"`
	CreatedTimestamp string `json:"created_timestamp"`
	Hash             string `json:"hash"`
}

type Image

type Image struct {
	Caption string `json:"caption,omitempty"`

	Sha256   string `json:"sha256"`
	ID       string `json:"id"`
	MimeType string `json:"mime_type"`
}

type Interactive

type Interactive struct {
	Type *InteractiveType `json:"type,omitempty"`
}

type InteractiveType

type InteractiveType struct {
	ButtonReply *ButtonReply `json:"button_reply,omitempty"`
	ListReply   *ListReply   `json:"list_reply,omitempty"`
}

type ListReply

type ListReply struct {
	ID          string `json:"id"`
	Title       string `json:"title"`
	Description string `json:"description"`
}

type Message

type Message struct {
	Audio       *Audio       `json:"audio,omitempty"`
	Button      *Button      `json:"button,omitempty"`
	Context     *Context     `json:"context,omitempty"`
	Document    *Document    `json:"document,omitempty"`
	Errors      []Error      `json:"errors,omitempty"`
	From        string       `json:"from"`
	ID          string       `json:"id"`
	Identity    *Identity    `json:"identity,omitempty"`
	Image       *Image       `json:"image,omitempty"`
	Interactive *Interactive `json:"interactive,omitempty"`
	Order       *Order       `json:"order,omitempty"`
	Referral    *Referral    `json:"referral,omitempty"`
	Sticker     *Sticker     `json:"sticker,omitempty"`
	System      *System      `json:"system,omitempty"`
	Text        *Text        `json:"text,omitempty"`
	Timestamp   time.Time    `json:"timestamp"`
	Type        string       `json:"type"`
	Video       *Video       `json:"video,omitempty"`
}

type Metadata

type Metadata struct {
	DisplayPhoneNumber string `json:"display_phone_number"`
	PhoneNumberID      string `json:"phone_number_id"`
}

type NotificationPayload

type NotificationPayload struct {
	Object string  `json:"object"`
	Entry  []Entry `json:"entry"`
}

type Order

type Order struct {
	CatalogID    string        `json:"catalog_id"`
	Text         string        `json:"text"`
	ProductItems []ProductItem `json:"product_items"`
}

type Origin

type Origin struct {
	Type               string `json:"type"`
	BusinessInitiated  bool   `json:"business_initiated"`
	CustomerInitiated  bool   `json:"customer_initiated"`
	ReferralConversion bool   `json:"referral_conversion"`
}

type Pricing

type Pricing struct {
	Billable     bool   `json:"billable"`
	Category     string `json:"category"`
	PricingModel string `json:"pricing_model"`
}

type ProductItem

type ProductItem struct {
	ProductRetailerID string `json:"product_retailer_id"`
	Quantity          string `json:"quantity"`
	ItemPrice         string `json:"item_price"`
	Currency          string `json:"currency"`
}

type Profile

type Profile struct {
	Name string `json:"name"`
}

type Referral

type Referral struct {
	SourceURL    string `json:"source_url"`
	SourceType   string `json:"source_type"`
	SourceID     string `json:"source_id"`
	Headline     string `json:"headline"`
	Body         string `json:"body"`
	MediaType    string `json:"media_type"`
	ImageURL     string `json:"image_url,omitempty"`
	VideoURL     string `json:"video_url,omitempty"`
	ThumbnailURL string `json:"thumbnail_url,omitempty"`
}

type ReferredProduct

type ReferredProduct struct {
	CatalogID         string `json:"catalog_id"`
	ProductRetailerID string `json:"product_retailer_id"`
}

type Status

type Status struct {
	Conversation Conversation `json:"conversation"`
	Errors       []Error      `json:"errors"`
	ID           string       `json:"id"`
	Pricing      Pricing      `json:"pricing"`
	RecipientID  string       `json:"recipient_id"`
	Status       string       `json:"status"`
	Timestamp    time.Time    `json:"timestamp"`
}

type Sticker

type Sticker struct {
	MimeType string `json:"mime_type"`
	Sha256   string `json:"sha256"`
	ID       string `json:"id"`
	Animated bool   `json:"animated"`
}

type System

type System struct {
	Body     string `json:"body"`
	Identity string `json:"identity"`
	NewWaID  string `json:"new_wa_id,omitempty"`
	WaID     string `json:"wa_id,omitempty"`
	Type     string `json:"type"`
	Customer string `json:"customer"`
}

type Text

type Text struct {
	Body string `json:"body"`
}

type Value

type Value struct {
	Contacts         []Contact `json:"contacts"`
	Errors           []Error   `json:"errors"`
	MessagingProduct string    `json:"messaging_product"`
	Messages         []Message `json:"messages"`
	Metadata         Metadata  `json:"metadata"`
	Statuses         []Status  `json:"statuses"`
}

type Video

type Video struct {
	Caption  string `json:"caption,omitempty"`
	Filename string `json:"filename"`
	Sha256   string `json:"sha256"`
	ID       string `json:"id"`
	MimeType string `json:"mime_type"`
}

Jump to

Keyboard shortcuts

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