types

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: May 5, 2026 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 Address

type Address struct {
	City    string   `json:"city,omitempty"`
	State   string   `json:"state,omitempty"`
	Zip     string   `json:"postalCode,omitempty"`
	Country string   `json:"country,omitempty"`
	Lines   []string `json:"lines,omitempty"`
}

type Attachment

type Attachment struct {
	ID       int    `json:"id"`
	FileName string `json:"filename"`
	MimeType string `json:"mimeType"`
	Size     int64  `json:"size,omitempty"`
}

type AttachmentCreate

type AttachmentCreate struct {
	FileName string `json:"filename"`
	MimeType string `json:"mimeType"`
	Data     string `json:"data"`
}

type Conversation

type Conversation struct {
	ID              int                 `json:"id"`
	Number          int                 `json:"number"`
	Subject         string              `json:"subject"`
	Status          string              `json:"status"`
	State           string              `json:"state"`
	Type            string              `json:"type"`
	MailboxID       int                 `json:"mailboxId"`
	AssignTo        int                 `json:"assignTo,omitempty"`
	CreatedAt       string              `json:"createdAt"`
	ModifiedAt      string              `json:"userUpdatedAt"`
	ClosedAt        string              `json:"closedAt,omitempty"`
	PrimaryCustomer Person              `json:"primaryCustomer"`
	Assignee        *Person             `json:"assignee,omitempty"`
	Preview         string              `json:"preview"`
	Tags            []Tag               `json:"tags,omitempty"`
	CC              []string            `json:"cc,omitempty"`
	BCC             []string            `json:"bcc,omitempty"`
	CustomFields    []ConversationField `json:"customFields,omitempty"`
	Source          struct {
		Type string `json:"type"`
		Via  string `json:"via"`
	} `json:"source,omitempty"`
	Threads []Thread `json:"-"`
}

type ConversationCreate

type ConversationCreate struct {
	Subject   string              `json:"subject"`
	MailboxID int                 `json:"mailboxId"`
	Type      string              `json:"type"`
	Status    string              `json:"status"`
	Customer  Person              `json:"customer"`
	Threads   []ThreadCreate      `json:"threads"`
	Tags      []string            `json:"tags,omitempty"`
	AssignTo  int                 `json:"assignTo,omitempty"`
	CreatedAt string              `json:"createdAt,omitempty"`
	Imported  *bool               `json:"imported,omitempty"`
	AutoReply *bool               `json:"autoReply,omitempty"`
	Fields    []ConversationField `json:"fields,omitempty"`
}

type ConversationField

type ConversationField struct {
	ID    int    `json:"id"`
	Value string `json:"value"`
}

type Customer

type Customer struct {
	ID         int     `json:"id"`
	FirstName  string  `json:"firstName"`
	LastName   string  `json:"lastName"`
	Email      string  `json:"email,omitempty"`
	Phone      string  `json:"phone,omitempty"`
	PhotoURL   string  `json:"photoUrl,omitempty"`
	PhotoType  string  `json:"photoType,omitempty"`
	CreatedAt  string  `json:"createdAt"`
	ModifiedAt string  `json:"updatedAt"`
	Emails     []Email `json:"-"` // populated from _embedded
}

type CustomerCreate

type CustomerCreate struct {
	FirstName string  `json:"firstName"`
	LastName  string  `json:"lastName,omitempty"`
	Emails    []Email `json:"emails,omitempty"`
	Phone     string  `json:"phone,omitempty"`
}

type CustomerUpdate

type CustomerUpdate struct {
	FirstName string `json:"firstName,omitempty"`
	LastName  string `json:"lastName,omitempty"`
	Phone     string `json:"phone,omitempty"`
}

type DocsPageInfo

type DocsPageInfo struct {
	Page  int `json:"page"`
	Pages int `json:"pages"`
	Count int `json:"count"`
}

type Email

type Email struct {
	Type  string `json:"type"`
	Value string `json:"value"`
}

type Mailbox

type Mailbox struct {
	ID         int    `json:"id"`
	Name       string `json:"name"`
	Slug       string `json:"slug"`
	Email      string `json:"email"`
	CreatedAt  string `json:"createdAt"`
	ModifiedAt string `json:"updatedAt"`
}

type NoteBody

type NoteBody struct {
	Text        string `json:"text"`
	User        int    `json:"user,omitempty"`
	Status      string `json:"status,omitempty"`
	Attachments []int  `json:"attachments,omitempty"`
}

type Organization

type Organization struct {
	ID     int    `json:"id"`
	Name   string `json:"name"`
	Domain string `json:"domain,omitempty"`
}

type OrganizationProperty

type OrganizationProperty struct {
	ID   int    `json:"id"`
	Name string `json:"name"`
	Type string `json:"type,omitempty"`
}

type PageInfo

type PageInfo struct {
	Number        int `json:"number"`
	Size          int `json:"size"`
	TotalElements int `json:"totalElements"`
	TotalPages    int `json:"totalPages"`
}

type Person

type Person struct {
	ID    int    `json:"id,omitempty"`
	Type  string `json:"type,omitempty"`
	Email string `json:"email,omitempty"`
	First string `json:"first,omitempty"`
	Last  string `json:"last,omitempty"`
}

type Property

type Property struct {
	ID   int    `json:"id"`
	Name string `json:"name"`
	Type string `json:"type,omitempty"`
}

type Rating

type Rating struct {
	ID       int    `json:"id"`
	Rating   string `json:"rating,omitempty"`
	Comments string `json:"comments,omitempty"`
}

type ReplyBody

type ReplyBody struct {
	Customer    Person   `json:"customer"`
	Text        string   `json:"text"`
	Status      string   `json:"status,omitempty"`
	Draft       *bool    `json:"draft,omitempty"`
	Imported    *bool    `json:"imported,omitempty"`
	User        int      `json:"user,omitempty"`
	To          []Person `json:"to,omitempty"`
	CC          []Person `json:"cc,omitempty"`
	BCC         []Person `json:"bcc,omitempty"`
	CreatedAt   string   `json:"createdAt,omitempty"`
	Type        string   `json:"type,omitempty"`
	Attachments []int    `json:"attachments,omitempty"`
}

type SavedReply

type SavedReply struct {
	ID        int    `json:"id"`
	MailboxID int    `json:"mailboxId,omitempty"`
	Name      string `json:"name"`
	Subject   string `json:"subject,omitempty"`
	Text      string `json:"text,omitempty"`
	IsPrivate bool   `json:"isPrivate,omitempty"`
	CreatedAt string `json:"createdAt,omitempty"`
	UpdatedAt string `json:"updatedAt,omitempty"`
}

type Tag

type Tag struct {
	ID    int    `json:"id"`
	Name  string `json:"name"`
	Slug  string `json:"slug"`
	Color string `json:"color"`
}

func (*Tag) UnmarshalJSON added in v0.2.3

func (t *Tag) UnmarshalJSON(data []byte) error

type Team

type Team struct {
	ID   int    `json:"id"`
	Name string `json:"name"`
}

type Thread

type Thread struct {
	ID          int          `json:"id"`
	Type        string       `json:"type"`
	Status      string       `json:"status"`
	State       string       `json:"state"`
	Body        string       `json:"body"`
	CreatedAt   string       `json:"createdAt"`
	CreatedBy   Person       `json:"createdBy"`
	Attachments []Attachment `json:"attachments,omitempty"`
	Source      struct {
		Type string `json:"type"`
		Via  string `json:"via"`
	} `json:"source"`
	Action struct {
		Text string `json:"text"`
		Type string `json:"type"`
	} `json:"action"`
}

type ThreadCreate

type ThreadCreate struct {
	Type     string `json:"type"`
	Customer Person `json:"customer,omitempty"`
	Text     string `json:"text"`
}

type ThreadCreateBody

type ThreadCreateBody struct {
	Customer    *Person `json:"customer,omitempty"`
	Text        string  `json:"text"`
	Imported    *bool   `json:"imported,omitempty"`
	CreatedAt   string  `json:"createdAt,omitempty"`
	Attachments []int   `json:"attachments,omitempty"`
}

type User

type User struct {
	ID         int    `json:"id"`
	FirstName  string `json:"firstName"`
	LastName   string `json:"lastName"`
	Email      string `json:"email"`
	Role       string `json:"role"`
	Type       string `json:"type"`
	CreatedAt  string `json:"createdAt"`
	ModifiedAt string `json:"updatedAt"`
	PhotoURL   string `json:"photoUrl,omitempty"`
}

type Webhook

type Webhook struct {
	ID             int      `json:"id"`
	URL            string   `json:"url"`
	State          string   `json:"state"`
	Events         []string `json:"events"`
	Secret         string   `json:"secret,omitempty"`
	CreatedAt      string   `json:"createdAt"`
	PayloadVersion string   `json:"payloadVersion,omitempty"`
	MailboxIDs     []int    `json:"mailboxIds,omitempty"`
	Notification   bool     `json:"notification,omitempty"`
	Label          string   `json:"label,omitempty"`
}

type WebhookCreate

type WebhookCreate struct {
	URL            string   `json:"url"`
	Events         []string `json:"events"`
	Secret         string   `json:"secret"`
	PayloadVersion string   `json:"payloadVersion,omitempty"`
	MailboxIDs     []int    `json:"mailboxIds,omitempty"`
	Notification   *bool    `json:"notification,omitempty"`
	Label          string   `json:"label,omitempty"`
}

type WebhookUpdate

type WebhookUpdate struct {
	URL            string   `json:"url,omitempty"`
	Events         []string `json:"events,omitempty"`
	Secret         string   `json:"secret,omitempty"`
	PayloadVersion string   `json:"payloadVersion,omitempty"`
	MailboxIDs     []int    `json:"mailboxIds,omitempty"`
	Notification   *bool    `json:"notification,omitempty"`
	Label          string   `json:"label,omitempty"`
}

type Workflow

type Workflow struct {
	ID         int    `json:"id"`
	Name       string `json:"name"`
	Type       string `json:"type"`
	Status     string `json:"status"`
	Order      int    `json:"order"`
	CreatedAt  string `json:"createdAt"`
	ModifiedAt string `json:"modifiedAt"`
	MailboxID  int    `json:"mailboxId"`
}

Jump to

Keyboard shortcuts

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