Documentation ¶
Overview ¶
Zendesk API client library for Go (golang).
Index ¶
- Constants
- func SetTimeout(timeout time.Duration) configOption
- func WithFilterForAction(action AuditLogAction) listAccountConfigurationAuditLogModifier
- func WithFilterForActorID(actorID ActorID) listAccountConfigurationAuditLogModifier
- func WithFilterForCreatedAt(startTime time.Time, endTime time.Time) listAccountConfigurationAuditLogModifier
- func WithFilterForIPAddress(ipAddress string) listAccountConfigurationAuditLogModifier
- func WithFilterForSourceID(sourceType string, sourceID uint64) listAccountConfigurationAuditLogModifier
- func WithFilterForSourceType(sourceType string) listAccountConfigurationAuditLogModifier
- func WithLogger(logger *log.Logger) configOption
- func WithPageSize(pageSize uint8) listAccountConfigurationAuditLogModifier
- func WithRequestPreProcessor(requestPreProcessor RequestPreProcessor) configOption
- func WithRoundTripper(roundTripper http.RoundTripper) configOption
- func WithSlogger(logger *slog.Logger) configOption
- func WithSort(field string, direction CursorPaginationSortDirection) listAccountConfigurationAuditLogModifier
- func WithUserAgent(userAgent string) configOption
- type AccountConfigurationService
- type ActorID
- type AgentEvent
- type AgentEventExportResponse
- type AgentEventService
- type AgentEventValue
- type AgentScopePermission
- type AgentState
- type AgentStates
- type Article
- type ArticleID
- type ArticleResponse
- type ArticleService
- type ArticlesResponse
- type AttachmentID
- type AuditID
- type AuditLog
- type AuditLogAction
- type AuditLogID
- type AuditLogService
- type AuditLogsResponse
- type AuthenticationPassword
- type AuthenticationToken
- type Brand
- type BrandID
- type BrandLogoAttachment
- type BrandResponse
- type BrandService
- type BrandsResponse
- type CategoriesResponse
- type Category
- type CategoryID
- type CategoryResponse
- type CategoryService
- type Chat
- type ChatAccountID
- type ChatCount
- type ChatCredentials
- type ChatEngagement
- type ChatEngagementID
- type ChatHistory
- type ChatID
- type ChatResponseTime
- type ChatSearchResult
- type ChatService
- func (s *ChatService) IncrementalExport(ctx context.Context, startTime time.Time, ...) error
- func (s *ChatService) List(ctx context.Context, pageHandler func(page ChatsResponse) error) error
- func (s *ChatService) Search(ctx context.Context, query string, ...) error
- func (s *ChatService) Show(ctx context.Context, id ChatID) (Chat, error)
- type ChatSession
- type ChatVisitor
- type ChatWebPath
- type ChatsIncrementalExportResponse
- type ChatsResponse
- type ChatsSearchResponse
- type CursorPaginationLinks
- type CursorPaginationMeta
- type CursorPaginationResponse
- type CursorPaginationSortDirection
- type CustomFieldOption
- type CustomFieldOptionID
- type CustomRole
- type CustomRoleConfiguration
- type CustomRoleCustomObject
- type CustomRoleID
- type CustomRoleResponse
- type CustomRoleService
- type CustomRolesResponse
- type CustomStatus
- type CustomStatusCategory
- type CustomStatusID
- type CustomStatusPayload
- type CustomStatusResponse
- type CustomStatusService
- func (s CustomStatusService) Create(ctx context.Context, payload CustomStatusPayload) (CustomStatusResponse, error)
- func (s CustomStatusService) List(ctx context.Context, pageHandler func(response CustomStatusesResponse) error) error
- func (s CustomStatusService) Show(ctx context.Context, id CustomStatusID) (CustomStatus, error)
- type CustomStatusesResponse
- type Error
- type ErrorDetail
- type Group
- type GroupID
- type GroupMembership
- type GroupMembershipID
- type GroupMembershipPayload
- type GroupMembershipResponse
- type GroupMembershipService
- func (s GroupMembershipService) Create(ctx context.Context, userID UserID, groupID GroupID) (GroupMembershipResponse, error)
- func (s GroupMembershipService) Delete(ctx context.Context, userID UserID, groupMembershipID GroupMembershipID) error
- func (s GroupMembershipService) List(ctx context.Context, pageHandler func(response GroupMembershipsResponse) error) error
- func (s GroupMembershipService) ListByGroup(ctx context.Context, groupID GroupID, ...) error
- func (s GroupMembershipService) ListByUser(ctx context.Context, userID UserID, ...) error
- func (s GroupMembershipService) SetDefault(ctx context.Context, userID UserID, groupMembershipID GroupMembershipID) (GroupMembershipsResponse, error)
- func (s GroupMembershipService) Show(ctx context.Context, id GroupMembershipID) (GroupMembership, error)
- type GroupMembershipsResponse
- type GroupPayload
- type GroupResponse
- type GroupsResponse
- type GroupsService
- type GuideService
- type IdentityID
- type IncrementalExportChat
- type IncrementalExportResponse
- type JobStatus
- type JobStatusResponse
- type ListAccountConfigurationAuditLogModifier
- type ListProblemTicketIncidentsResponse
- type LiveChatService
- type MalwareScanResult
- type MergeRequestPayload
- type OffsetPaginationResponse
- type Organization
- type OrganizationAutocompleteResponse
- type OrganizationFieldConfiguration
- type OrganizationFieldConfigurationResponse
- type OrganizationFieldID
- type OrganizationFieldPayload
- type OrganizationFieldService
- func (s OrganizationFieldService) Create(ctx context.Context, payload OrganizationFieldPayload) (OrganizationFieldConfigurationResponse, error)
- func (s OrganizationFieldService) Delete(ctx context.Context, id OrganizationFieldID) error
- func (s OrganizationFieldService) List(ctx context.Context, ...) error
- func (s OrganizationFieldService) Show(ctx context.Context, id OrganizationFieldID) (OrganizationFieldConfiguration, error)
- func (s OrganizationFieldService) Update(ctx context.Context, id OrganizationFieldID, payload OrganizationFieldPayload) (OrganizationFieldConfigurationResponse, error)
- type OrganizationFieldType
- type OrganizationFields
- type OrganizationFieldsConfigurationResponse
- type OrganizationID
- type OrganizationMembership
- type OrganizationMembershipID
- type OrganizationMembershipPayload
- type OrganizationMembershipPayloadData
- type OrganizationMembershipResponse
- type OrganizationMembershipService
- func (s OrganizationMembershipService) Create(ctx context.Context, payload OrganizationMembershipPayload) (OrganizationMembershipResponse, error)
- func (s OrganizationMembershipService) List(ctx context.Context, ...) error
- func (s OrganizationMembershipService) Show(ctx context.Context, id OrganizationMembershipID) (OrganizationMembership, error)
- type OrganizationMembershipsResponse
- type OrganizationPayload
- type OrganizationResponse
- type OrganizationSatisfactionRating
- type OrganizationService
- func (s OrganizationService) Autocomplete(ctx context.Context, term string, ...) error
- func (s OrganizationService) Create(ctx context.Context, payload OrganizationPayload) (OrganizationResponse, error)
- func (s OrganizationService) IncrementalExport(ctx context.Context, startTime int64, ...) error
- func (s OrganizationService) Show(ctx context.Context, id OrganizationID) (Organization, error)
- func (s OrganizationService) Update(ctx context.Context, id OrganizationID, payload OrganizationPayload) (OrganizationResponse, error)
- type OrganizationVia
- type OrganizationsIncrementalExportResponse
- type OrganizationsResponse
- type PermissionGroupID
- type ReasonCode
- type ReasonID
- type RequestPreProcessor
- type RequestPreProcessorFunc
- type SatisfactionRating
- type SatisfactionRatingID
- type SatisfactionRatingResponse
- type SatisfactionRatingScore
- type SatisfactionRatingService
- type SatisfactionRatingsResponse
- type Schedule
- type ScheduleID
- type ScheduleInterval
- type ScheduleService
- type SchedulesResponse
- type Section
- type SectionID
- type SectionService
- type SectionsResponse
- type Service
- type SideConversationCreatePayload
- type SideConversationMessage
- type SideConversationService
- type SideConversationTarget
- type SideConversationTargetChildTicket
- type SourceID
- type SupportService
- func (s *SupportService) CustomStatuses() *CustomStatusService
- func (s *SupportService) GroupMemberships() *GroupMembershipService
- func (s *SupportService) Groups() *GroupsService
- func (s *SupportService) OrganizationFields() *OrganizationFieldService
- func (s *SupportService) OrganizationMemberships() *OrganizationMembershipService
- func (s *SupportService) Organizations() *OrganizationService
- func (s *SupportService) SatisfactionRatings() *SatisfactionRatingService
- func (s *SupportService) Schedules() *ScheduleService
- func (s *SupportService) SideConversations() *SideConversationService
- func (s *SupportService) SuspendedTickets() *SuspendedTicketService
- func (s *SupportService) TicketAttachments() *TicketAttachmentService
- func (s *SupportService) TicketAudits() *TicketAuditService
- func (s *SupportService) TicketComments() *TicketCommentService
- func (s *SupportService) TicketFields() *TicketFieldService
- func (s *SupportService) TicketForms() *TicketFormService
- func (s *SupportService) TicketTags() *TicketTagService
- func (s *SupportService) Tickets() *TicketService
- func (s *SupportService) UserFields() *UserFieldService
- func (s *SupportService) UserIdentities() *UserIdentityService
- func (s *SupportService) Users() *UserService
- type SuspendedTicket
- type SuspendedTicketID
- type SuspendedTicketService
- func (s *SuspendedTicketService) Delete(ctx context.Context, id SuspendedTicketID) error
- func (s SuspendedTicketService) List(ctx context.Context, pageHandler func(response SuspendedTicketsResponse) error) error
- func (s *SuspendedTicketService) RecoverMultiple(ctx context.Context, ids []SuspendedTicketID) error
- type SuspendedTicketsResponse
- type Tag
- type TagMeta
- type TagSearchResponse
- type Tags
- type TagsPayload
- type TagsResponse
- type Ticket
- type TicketAttachment
- type TicketAttachmentResponse
- type TicketAttachmentService
- func (s TicketAttachmentService) Download(ctx context.Context, contentURL string, writer io.Writer) error
- func (s *TicketAttachmentService) DownloadToFile(ctx context.Context, contentURL string, filePath string) error
- func (s TicketAttachmentService) Show(ctx context.Context, attachmentID AttachmentID) (TicketAttachment, error)
- func (s TicketAttachmentService) Upload(ctx context.Context, localFilePath string, uploadToken UploadToken) (TicketAttachmentUploadResponse, error)
- func (s TicketAttachmentService) UploadWithFilename(ctx context.Context, localFilePath string, filename string, ...) (TicketAttachmentUploadResponse, error)
- type TicketAttachmentUploadResponse
- type TicketAudit
- type TicketAuditEvent
- type TicketAuditEventID
- type TicketAuditID
- type TicketAuditResponse
- type TicketAuditService
- type TicketAuditsResponse
- type TicketComment
- type TicketCommentID
- type TicketCommentMetadata
- type TicketCommentMetadataSystem
- type TicketCommentResponse
- type TicketCommentService
- type TicketCommentSideload
- type TicketDates
- type TicketField
- type TicketFieldConfiguration
- type TicketFieldConfigurationResponse
- type TicketFieldID
- type TicketFieldService
- type TicketFieldType
- type TicketFields
- type TicketFieldsConfigurationResponse
- type TicketForm
- type TicketFormID
- type TicketFormResponse
- type TicketFormService
- type TicketFormsResponse
- type TicketID
- type TicketPayload
- type TicketResponse
- type TicketSatisfactionRating
- type TicketService
- func (s TicketService) AddTags(ctx context.Context, ticketID TicketID, tags Tags) (Tags, error)
- func (s TicketService) Create(ctx context.Context, payload TicketPayload) (TicketResponse, error)
- func (s TicketService) Import(ctx context.Context, payload TicketPayload) (TicketResponse, error)
- func (s TicketService) IncrementalExport(ctx context.Context, startTime time.Time, perPage uint, ...) error
- func (s TicketService) IncrementalExportWithSideloads(ctx context.Context, startTime time.Time, sideloads []TicketSideload, ...) error
- func (s TicketService) ListProblemTicketIncidents(ctx context.Context, problemTicket TicketID, ...) error
- func (s TicketService) Merge(ctx context.Context, destination TicketID, payload MergeRequestPayload) (JobStatusResponse, error)
- func (s TicketService) RemoveTags(ctx context.Context, ticketID TicketID, tags Tags) (Tags, error)
- func (s TicketService) SetTags(ctx context.Context, ticketID TicketID, tags Tags) (Tags, error)
- func (s TicketService) Show(ctx context.Context, id TicketID) (Ticket, error)
- func (s TicketService) Update(ctx context.Context, id TicketID, payload TicketPayload) (TicketResponse, error)
- type TicketSideload
- type TicketTagService
- type TicketVia
- type TicketsIncrementalExportResponse
- type TicketsResponse
- type UploadToken
- type User
- type UserFieldConfiguration
- type UserFieldConfigurationResponse
- type UserFieldID
- type UserFieldService
- type UserFieldType
- type UserFields
- type UserFieldsConfigurationResponse
- type UserID
- type UserIdentitiesResponse
- type UserIdentity
- type UserIdentityPayload
- type UserIdentityResponse
- type UserIdentityService
- type UserPayload
- type UserPhoto
- type UserResponse
- type UserRole
- type UserSearchResponse
- type UserSegmentID
- type UserService
- func (s UserService) Create(ctx context.Context, payload UserPayload) (UserResponse, error)
- func (s UserService) IncrementalExport(ctx context.Context, startTime int64, ...) error
- func (s UserService) IncrementalExportWithSideloads(ctx context.Context, startTime int64, sideloads []UserSideload, ...) error
- func (s UserService) Search(ctx context.Context, query string) (UsersResponse, error)
- func (s UserService) SearchWithSideloads(ctx context.Context, query string, sideloads []UserSideload, ...) error
- func (s UserService) Show(ctx context.Context, id UserID) (User, error)
- func (s UserService) ShowSelf(ctx context.Context) (User, error)
- func (s UserService) ShowWithSideloads(ctx context.Context, id UserID, sideloads []UserSideload) (UserResponse, error)
- func (s UserService) Update(ctx context.Context, id UserID, payload UserPayload) (UserResponse, error)
- type UserSideload
- type UserTicketRestriction
- type UsersIncrementalExportResponse
- type UsersResponse
Constants ¶
const ( PriorityUrgent = "urgent" PriorityHigh = "high" PriorityNormal = "normal" PriorityLow = "low" )
const ( StatusNew = "new" StatusOpen = "open" StatusPending = "pending" StatusHold = "hold" StatusSolved = "solved" StatusClosed = "closed" StatusDeleted = "deleted" )
Variables ¶
This section is empty.
Functions ¶
func SetTimeout ¶ added in v0.0.29
func WithFilterForAction ¶ added in v0.0.21
func WithFilterForAction(action AuditLogAction) listAccountConfigurationAuditLogModifier
func WithFilterForActorID ¶ added in v0.0.21
func WithFilterForActorID(actorID ActorID) listAccountConfigurationAuditLogModifier
func WithFilterForCreatedAt ¶ added in v0.0.21
func WithFilterForIPAddress ¶ added in v0.0.26
func WithFilterForIPAddress(ipAddress string) listAccountConfigurationAuditLogModifier
func WithFilterForSourceID ¶ added in v0.0.21
func WithFilterForSourceID(sourceType string, sourceID uint64) listAccountConfigurationAuditLogModifier
Filter audit logs by the source id. Requires filter[source_type] to also be set.
func WithFilterForSourceType ¶ added in v0.0.21
func WithFilterForSourceType(sourceType string) listAccountConfigurationAuditLogModifier
func WithLogger ¶
func WithPageSize ¶ added in v0.0.24
func WithPageSize(pageSize uint8) listAccountConfigurationAuditLogModifier
func WithRequestPreProcessor ¶
func WithRequestPreProcessor(requestPreProcessor RequestPreProcessor) configOption
func WithRoundTripper ¶
func WithRoundTripper(roundTripper http.RoundTripper) configOption
func WithSlogger ¶ added in v0.0.38
func WithSort ¶ added in v0.0.24
func WithSort(field string, direction CursorPaginationSortDirection) listAccountConfigurationAuditLogModifier
func WithUserAgent ¶ added in v0.0.17
func WithUserAgent(userAgent string) configOption
Types ¶
type AccountConfigurationService ¶ added in v0.0.21
type AccountConfigurationService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/account-configuration/account_settings/
func (*AccountConfigurationService) AuditLogs ¶ added in v0.0.21
func (s *AccountConfigurationService) AuditLogs() *AuditLogService
https://developer.zendesk.com/api-reference/ticketing/account-configuration/audit_logs/
func (*AccountConfigurationService) Brands ¶ added in v0.0.39
func (s *AccountConfigurationService) Brands() *BrandService
https://developer.zendesk.com/api-reference/ticketing/account-configuration/brands/
func (*AccountConfigurationService) CustomRoles ¶ added in v0.0.35
func (s *AccountConfigurationService) CustomRoles() *CustomRoleService
https://developer.zendesk.com/api-reference/ticketing/account-configuration/custom_roles/
type AgentEvent ¶ added in v0.0.4
type AgentEvent struct { StartTime time.Time `json:"timestamp"` AccountID ChatAccountID `json:"account_id"` AgentID UserID `json:"agent_id"` FieldName string `json:"field_name"` ID string `json:"id"` PreviousValue AgentEventValue `json:"previous_value"` Value AgentEventValue `json:"value"` }
type AgentEventExportResponse ¶ added in v0.0.4
type AgentEventExportResponse struct { AgentEvents []AgentEvent `json:"agent_events"` EndTimeUnix float64 `json:"end_time"` NextPage string `json:"next_page"` Count int64 `json:"count"` }
func (AgentEventExportResponse) EndTime ¶ added in v0.0.4
func (response AgentEventExportResponse) EndTime() time.Time
type AgentEventService ¶ added in v0.0.4
type AgentEventService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/live-chat/chat-api/incremental_agent_events_api/
func (*AgentEventService) GetAgentStates ¶ added in v0.0.4
func (s *AgentEventService) GetAgentStates( ctx context.Context, ) AgentStates
func (*AgentEventService) IncrementalExport ¶ added in v0.0.4
func (s *AgentEventService) IncrementalExport( ctx context.Context, startTime time.Time, pageHandler func(response AgentEventExportResponse) error, ) error
func (*AgentEventService) UpdateAgentStates ¶ added in v0.0.4
type AgentEventValue ¶ added in v0.0.4
type AgentEventValue string
func (*AgentEventValue) UnmarshalJSON ¶ added in v0.0.4
func (a *AgentEventValue) UnmarshalJSON(data []byte) error
type AgentScopePermission ¶ added in v0.0.35
type AgentScopePermission string
const ( ScopeRead AgentScopePermission = "read" ScopeUpdate AgentScopePermission = "update" ScopeDelete AgentScopePermission = "delete" ScopeCreate AgentScopePermission = "create" )
type AgentState ¶ added in v0.0.4
type AgentStates ¶ added in v0.0.4
type AgentStates map[UserID]AgentState
type Article ¶
type Article struct { AuthorID UserID `json:"author_id"` Body string `json:"body"` CommentsDisabled bool `json:"comments_disabled"` ContentTagIds []any `json:"content_tag_ids"` CreatedAt time.Time `json:"created_at"` Draft bool `json:"draft"` EditedAt time.Time `json:"edited_at"` HTMLURL string `json:"html_url"` ID ArticleID `json:"id"` LabelNames []any `json:"label_names"` Locale string `json:"locale"` Name string `json:"name"` Outdated bool `json:"outdated"` PermissionGroupID PermissionGroupID `json:"permission_group_id"` Position int64 `json:"position"` Promoted bool `json:"promoted"` SectionID SectionID `json:"section_id"` SourceLocale string `json:"source_locale"` Title string `json:"title"` UpdatedAt time.Time `json:"updated_at"` URL string `json:"url"` UserSegmentID UserSegmentID `json:"user_segment_id"` VoteCount uint64 `json:"vote_count"` VoteSum int64 `json:"vote_sum"` }
type ArticleResponse ¶
type ArticleResponse struct {
Article Article `json:"article"`
}
type ArticleService ¶ added in v0.0.12
type ArticleService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/help_center/help-center-api/articles/
func (ArticleService) List ¶ added in v0.0.12
func (s ArticleService) List( ctx context.Context, pageHandler func(response ArticlesResponse) error, ) error
https://developer.zendesk.com/api-reference/help_center/help-center-api/articles/#list-articles
func (ArticleService) Show ¶ added in v0.0.12
https://developer.zendesk.com/api-reference/help_center/help-center-api/articles/#show-article
type ArticlesResponse ¶
type ArticlesResponse struct { Articles []Article `json:"articles"` CursorPaginationResponse }
type AttachmentID ¶ added in v0.0.35
type AttachmentID uint64
type AuditLog ¶ added in v0.0.21
type AuditLog struct { Action AuditLogAction `json:"action"` ActionLabel string `json:"action_label"` ActorID ActorID `json:"actor_id"` ActorName string `json:"actor_name"` ChangeDescription string `json:"change_description"` CreatedAt time.Time `json:"created_at"` ID AuditLogID `json:"id"` IPAddress *string `json:"ip_address"` SourceID SourceID `json:"source_id"` SourceLabel string `json:"source_label"` SourceType string `json:"source_type"` URL string `json:"url"` }
https://developer.zendesk.com/api-reference/ticketing/account-configuration/audit_logs/#json-format
type AuditLogAction ¶ added in v0.0.21
type AuditLogAction string
const ( Create AuditLogAction = "create" Destroy AuditLogAction = "destroy" Exported AuditLogAction = "exported" Login AuditLogAction = "login" Update AuditLogAction = "update" )
type AuditLogID ¶ added in v0.0.21
type AuditLogID uint64
type AuditLogService ¶ added in v0.0.21
type AuditLogService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/account-configuration/audit_logs/
func (AuditLogService) List ¶ added in v0.0.21
func (s AuditLogService) List( ctx context.Context, pageHandler func(response AuditLogsResponse) error, modifiers ...ListAccountConfigurationAuditLogModifier, ) error
type AuditLogsResponse ¶ added in v0.0.21
type AuditLogsResponse struct { AuditLogs []AuditLog `json:"audit_logs"` CursorPaginationResponse }
type AuthenticationPassword ¶
func (AuthenticationPassword) AddZendeskAuthentication ¶
func (auth AuthenticationPassword) AddZendeskAuthentication(r *http.Request)
type AuthenticationToken ¶
func (AuthenticationToken) AddZendeskAuthentication ¶
func (auth AuthenticationToken) AddZendeskAuthentication(r *http.Request)
type Brand ¶ added in v0.0.39
type Brand struct { Active bool `json:"active"` BrandURL string `json:"brand_url"` CreatedAt time.Time `json:"created_at"` Default bool `json:"default"` HasHelpCenter bool `json:"has_help_center"` HelpCenterState string `json:"help_center_state"` HostMapping string `json:"host_mapping"` ID BrandID `json:"id"` IsDeleted bool `json:"is_deleted"` Logo BrandLogoAttachment `json:"logo"` Name string `json:"name"` SignatureTemplate string `json:"signature_template"` Subdomain string `json:"subdomain"` TicketFormIDs []TicketFormID `json:"ticket_form_ids"` UpdatedAt *time.Time `json:"updated_at"` URL string `json:"url"` }
https://developer.zendesk.com/api-reference/ticketing/account-configuration/brands/#json-format
type BrandLogoAttachment ¶ added in v0.0.39
type BrandLogoAttachment struct { ContentType string `json:"content_type"` ContentURL string `json:"content_url"` Deleted bool `json:"deleted"` FileName string `json:"file_name"` Height uint64 `json:"height"` ID AttachmentID `json:"id"` Inline bool `json:"inline"` MappedContentURL string `json:"mapped_content_url"` Size uint64 `json:"size"` URL string `json:"url"` Width uint64 `json:"width"` }
type BrandResponse ¶ added in v0.0.39
type BrandResponse struct {
Brand Brand `json:"brand"`
}
type BrandService ¶ added in v0.0.39
type BrandService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/account-configuration/brands/
func (BrandService) List ¶ added in v0.0.39
func (s BrandService) List( ctx context.Context, pageHandler func(response BrandsResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/account-configuration/brands/#list-brands
func (BrandService) Show ¶ added in v0.0.39
https://developer.zendesk.com/api-reference/ticketing/account-configuration/brands/#show-a-brand
type BrandsResponse ¶ added in v0.0.39
type BrandsResponse struct { Brands []Brand `json:"brands"` CursorPaginationResponse }
type CategoriesResponse ¶
type CategoriesResponse struct { Categories []Category `json:"categories"` CursorPaginationResponse }
type Category ¶
type Category struct { CreatedAt time.Time `json:"created_at"` Description string `json:"description"` HTMLURL string `json:"html_url"` ID CategoryID `json:"id"` Locale string `json:"locale"` Name string `json:"name"` Outdated bool `json:"outdated"` Position int64 `json:"position"` SourceLocale string `json:"source_locale"` UpdatedAt time.Time `json:"updated_at"` URL string `json:"url"` }
type CategoryID ¶
type CategoryID uint64
type CategoryResponse ¶
type CategoryResponse struct {
Category Category `json:"category"`
}
type CategoryService ¶ added in v0.0.12
type CategoryService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/help_center/help-center-api/categories/
func (CategoryService) List ¶ added in v0.0.26
func (s CategoryService) List( ctx context.Context, pageHandler func(response CategoriesResponse) error, ) error
type Chat ¶
type Chat struct { ID ChatID `json:"id"` Visitor ChatVisitor `json:"visitor"` StartedBy string `json:"started_by"` Session ChatSession `json:"session"` WebPath []ChatWebPath `json:"webpath"` Timestamp time.Time `json:"timestamp"` Count ChatCount `json:"count"` Duration uint64 `json:"duration"` ResponseTime ChatResponseTime `json:"response_time"` AgentIds []UserID `json:"agent_ids"` Triggered bool `json:"triggered"` Unread bool `json:"unread"` Missed bool `json:"missed"` Tags []Tag `json:"tags"` Type string `json:"type"` History []ChatHistory `json:"history"` DepartmentID *GroupID `json:"department_id"` EndTimestamp time.Time `json:"end_timestamp"` ZendeskTicketID TicketID `json:"zendesk_ticket_id"` }
type ChatAccountID ¶ added in v0.0.12
type ChatAccountID uint64
type ChatCredentials ¶
type ChatEngagement ¶ added in v0.0.2
type ChatEngagement struct { ID ChatEngagementID `json:"id"` AgentID UserID `json:"agent_id"` DepartmentID *GroupID `json:"department_id"` Assigned bool `json:"assigned"` Accepted bool `json:"accepted"` StartedBy string `json:"started_by"` Timestamp time.Time `json:"timestamp"` Duration float64 `json:"duration"` Count ChatCount `json:"count"` ResponseTime ChatResponseTime `json:"response_time"` }
type ChatEngagementID ¶ added in v0.0.2
type ChatEngagementID string
type ChatHistory ¶
type ChatHistory struct { DepartmentID GroupID `json:"department_id"` DepartmentName string `json:"department_name"` Name string `json:"name"` Channel string `json:"channel"` Index int `json:"index"` Timestamp time.Time `json:"timestamp"` Type string `json:"type"` Msg string `json:"msg"` Options string `json:"options"` MsgID string `json:"msg_id"` SenderType string `json:"sender_type"` Source string `json:"source"` AgentID UserID `json:"agent_id,string"` Reason string `json:"reason"` }
type ChatResponseTime ¶
type ChatSearchResult ¶ added in v0.0.3
type ChatService ¶
type ChatService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/live-chat/chat-api/chats/
func (*ChatService) IncrementalExport ¶ added in v0.0.12
func (s *ChatService) IncrementalExport( ctx context.Context, startTime time.Time, pageHandler func(response ChatsIncrementalExportResponse) error, ) error
func (*ChatService) List ¶ added in v0.0.12
func (s *ChatService) List(ctx context.Context, pageHandler func(page ChatsResponse) error) error
https://developer.zendesk.com/api-reference/live-chat/chat-api/chats/#list-chats
func (*ChatService) Search ¶ added in v0.0.12
func (s *ChatService) Search(ctx context.Context, query string, pageHandler func(page ChatsSearchResponse) error) error
https://developer.zendesk.com/api-reference/live-chat/chat-api/chats/#search-chats
func (*ChatService) Show ¶ added in v0.0.12
https://developer.zendesk.com/api-reference/live-chat/chat-api/chats/#show-chat
type ChatSession ¶
type ChatSession struct { EndDate time.Time `json:"end_date"` CountryCode string `json:"country_code"` City string `json:"city"` Browser string `json:"browser"` IP string `json:"ip"` CountryName string `json:"country_name"` ID string `json:"id"` Region string `json:"region"` Platform string `json:"platform"` UserAgent string `json:"user_agent"` StartDate time.Time `json:"start_date"` }
type ChatVisitor ¶
type ChatWebPath ¶
type ChatsIncrementalExportResponse ¶
type ChatsIncrementalExportResponse struct { Chats []IncrementalExportChat `json:"chats"` Count uint64 `json:"count"` EndID ChatID `json:"end_id"` EndTimeUnix int64 `json:"end_time"` NextPage string `json:"next_page"` }
func (ChatsIncrementalExportResponse) EndTime ¶
func (response ChatsIncrementalExportResponse) EndTime() time.Time
type ChatsResponse ¶
type ChatsSearchResponse ¶ added in v0.0.3
type ChatsSearchResponse struct { Results []ChatSearchResult `json:"results"` NextURL *string `json:"next_url"` }
type CursorPaginationLinks ¶
type CursorPaginationMeta ¶
type CursorPaginationResponse ¶
type CursorPaginationResponse struct { Meta CursorPaginationMeta `json:"meta"` Links CursorPaginationLinks `json:"links"` }
https://developer.zendesk.com/api-reference/introduction/pagination/#using-cursor-pagination
type CursorPaginationSortDirection ¶ added in v0.0.24
type CursorPaginationSortDirection string
const ( Asc CursorPaginationSortDirection = "" Desc CursorPaginationSortDirection = "-" )
type CustomFieldOption ¶ added in v0.0.12
type CustomFieldOptionID ¶ added in v0.0.12
type CustomFieldOptionID uint64
type CustomRole ¶ added in v0.0.35
type CustomRole struct { Configuration CustomRoleConfiguration `json:"configuration"` CreatedAt time.Time `json:"created_at"` Description string `json:"description"` ID CustomRoleID `json:"id"` Name string `json:"name"` RoleType uint64 `json:"role_type"` TeamMemberCount uint64 `json:"team_member_count"` UpdatedAt time.Time `json:"updated_at"` }
type CustomRoleConfiguration ¶ added in v0.0.35
type CustomRoleConfiguration struct { AssignTicketsToAnyGroup bool `json:"assign_tickets_to_any_group"` ChatAccess bool `json:"chat_access"` CustomObjects map[string]CustomRoleCustomObject `json:"custom_objects"` EndUserListAccess string `json:"end_user_list_access"` EndUserProfileAccess string `json:"end_user_profile_access"` ExploreAccess string `json:"explore_access"` ForumAccess string `json:"forum_access"` ForumAccessRestrictedContent bool `json:"forum_access_restricted_content"` GroupAccess bool `json:"group_access"` LightAgent bool `json:"light_agent"` MacroAccess string `json:"macro_access"` ManageAutomations bool `json:"manage_automations"` ManageBusinessRules bool `json:"manage_business_rules"` ManageContextualWorkspaces bool `json:"manage_contextual_workspaces"` ManageDynamicContent bool `json:"manage_dynamic_content"` ManageExtensionsAndChannels bool `json:"manage_extensions_and_channels"` ManageFacebook bool `json:"manage_facebook"` ManageGroupMemberships bool `json:"manage_group_memberships"` ManageGroups bool `json:"manage_groups"` ManageOrganizationFields bool `json:"manage_organization_fields"` ManageOrganizations bool `json:"manage_organizations"` ManageRoles string `json:"manage_roles"` ManageSkills bool `json:"manage_skills"` ManageSLAs bool `json:"manage_slas"` ManageSuspendedTickets bool `json:"manage_suspended_tickets"` ManageTeamMembers string `json:"manage_team_members"` ManageTicketFields bool `json:"manage_ticket_fields"` ManageTicketForms bool `json:"manage_ticket_forms"` ManageTriggers bool `json:"manage_triggers"` ManageUserFields bool `json:"manage_user_fields"` ModerateForums bool `json:"moderate_forums"` OrganizationEditing bool `json:"organization_editing"` OrganizationNotesEditing bool `json:"organization_notes_editing"` ReportAccess string `json:"report_access"` SideConversationCreate bool `json:"side_conversation_create"` TicketAccess string `json:"ticket_access"` TicketCommentAccess string `json:"ticket_comment_access"` TicketDeletion bool `json:"ticket_deletion"` TicketEditing bool `json:"ticket_editing"` TicketMerge bool `json:"ticket_merge"` TicketRedaction bool `json:"ticket_redaction"` TicketTagEditing bool `json:"ticket_tag_editing"` TwitterSearchAccess bool `json:"twitter_search_access"` UserViewAccess string `json:"user_view_access"` ViewAccess string `json:"view_access"` ViewDeletedTickets bool `json:"view_deleted_tickets"` VoiceAccess bool `json:"voice_access"` VoiceDashboardAccess bool `json:"voice_dashboard_access"` }
type CustomRoleCustomObject ¶ added in v0.0.35
type CustomRoleCustomObject struct {
Scopes []AgentScopePermission `json:"scopes"`
}
A list of custom object keys mapped to JSON objects that define the agent's permissions (scopes) for each object. Allowed values: "read", "update", "delete", "create". The "read" permission is required if any other scopes are specified. Example: { "shipment": { "scopes": ["read", "update"] } }.
type CustomRoleID ¶ added in v0.0.12
type CustomRoleID uint64
type CustomRoleResponse ¶ added in v0.0.35
type CustomRoleResponse struct {
CustomRole CustomRole `json:"custom_role"`
}
type CustomRoleService ¶ added in v0.0.35
type CustomRoleService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/account-configuration/custom_roles
func (CustomRoleService) List ¶ added in v0.0.35
func (s CustomRoleService) List( ctx context.Context, pageHandler func(response CustomRolesResponse) error, ) error
Does not support cursor pagination.
func (CustomRoleService) Show ¶ added in v0.0.35
func (s CustomRoleService) Show(ctx context.Context, id CustomRoleID) (CustomRole, error)
type CustomRolesResponse ¶ added in v0.0.35
type CustomRolesResponse struct { CustomRoles []CustomRole `json:"custom_roles"` OffsetPaginationResponse }
type CustomStatus ¶ added in v0.0.35
type CustomStatus struct { Active bool `json:"active"` ID CustomStatusID `json:"id"` AgentLabel string `json:"agent_label"` StatusCategory CustomStatusCategory `json:"status_category"` }
https://developer.zendesk.com/api-reference/ticketing/tickets/custom_ticket_statuses/#json-format
type CustomStatusCategory ¶ added in v0.0.35
type CustomStatusCategory string
const ( StatusCategoryNew CustomStatusCategory = "new" StatusCategoryOpen CustomStatusCategory = "open" StatusCategoryPending CustomStatusCategory = "pending" StatusCategoryHold CustomStatusCategory = "hold" // Tickets with a "Closed" status belong to the "StatusCategorySolved" status category. StatusCategorySolved CustomStatusCategory = "solved" )
type CustomStatusID ¶ added in v0.0.35
type CustomStatusID uint64
type CustomStatusPayload ¶ added in v0.0.35
type CustomStatusPayload struct {
CustomStatus any `json:"custom_status"`
}
type CustomStatusResponse ¶ added in v0.0.35
type CustomStatusResponse struct {
CustomStatus CustomStatus `json:"custom_status"`
}
type CustomStatusService ¶ added in v0.0.35
type CustomStatusService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/custom_ticket_statuses/
func (CustomStatusService) Create ¶ added in v0.0.35
func (s CustomStatusService) Create(ctx context.Context, payload CustomStatusPayload) (CustomStatusResponse, error)
func (CustomStatusService) List ¶ added in v0.0.35
func (s CustomStatusService) List( ctx context.Context, pageHandler func(response CustomStatusesResponse) error, ) error
Does not support cursor pagination.
func (CustomStatusService) Show ¶ added in v0.0.35
func (s CustomStatusService) Show(ctx context.Context, id CustomStatusID) (CustomStatus, error)
type CustomStatusesResponse ¶ added in v0.0.35
type CustomStatusesResponse struct { CustomStatuses []CustomStatus `json:"custom_statuses"` OffsetPaginationResponse }
type Error ¶
type Error struct { Response *http.Response `json:"response"` Message string `json:"message"` Description string `json:"description"` }
func (*Error) ImmutableRecord ¶ added in v0.0.12
func (*Error) UnmarshalJSON ¶
type ErrorDetail ¶ added in v0.0.38
type GroupMembership ¶ added in v0.0.12
type GroupMembershipID ¶ added in v0.0.12
type GroupMembershipID uint64
type GroupMembershipPayload ¶ added in v0.0.12
type GroupMembershipPayload struct {
GroupMembership any `json:"group_membership"`
}
type GroupMembershipResponse ¶ added in v0.0.12
type GroupMembershipResponse struct {
GroupMembership GroupMembership `json:"group_membership"`
}
type GroupMembershipService ¶ added in v0.0.12
type GroupMembershipService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/
func (GroupMembershipService) Create ¶ added in v0.0.12
func (s GroupMembershipService) Create( ctx context.Context, userID UserID, groupID GroupID, ) (GroupMembershipResponse, error)
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/#create-membership
func (GroupMembershipService) Delete ¶ added in v0.0.12
func (s GroupMembershipService) Delete( ctx context.Context, userID UserID, groupMembershipID GroupMembershipID, ) error
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/#delete-membership
func (GroupMembershipService) List ¶ added in v0.0.12
func (s GroupMembershipService) List( ctx context.Context, pageHandler func(response GroupMembershipsResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/#list-memberships
func (GroupMembershipService) ListByGroup ¶ added in v0.0.12
func (s GroupMembershipService) ListByGroup( ctx context.Context, groupID GroupID, pageHandler func(response GroupMembershipsResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/#list-memberships
func (GroupMembershipService) ListByUser ¶ added in v0.0.12
func (s GroupMembershipService) ListByUser( ctx context.Context, userID UserID, pageHandler func(response GroupMembershipsResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/#list-memberships
func (GroupMembershipService) SetDefault ¶ added in v0.0.12
func (s GroupMembershipService) SetDefault( ctx context.Context, userID UserID, groupMembershipID GroupMembershipID, ) (GroupMembershipsResponse, error)
func (GroupMembershipService) Show ¶ added in v0.0.38
func (s GroupMembershipService) Show( ctx context.Context, id GroupMembershipID, ) (GroupMembership, error)
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/#show-membership
type GroupMembershipsResponse ¶ added in v0.0.12
type GroupMembershipsResponse struct { GroupMemberships []GroupMembership `json:"group_memberships"` CursorPaginationResponse }
type GroupPayload ¶ added in v0.0.35
type GroupPayload struct {
Group any `json:"group"`
}
type GroupResponse ¶ added in v0.0.35
type GroupResponse struct {
Group Group `json:"group"`
}
type GroupsResponse ¶ added in v0.0.12
type GroupsResponse struct { Groups []Group `json:"groups"` CursorPaginationResponse }
type GroupsService ¶ added in v0.0.12
type GroupsService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/groups/groups/
func (GroupsService) Create ¶ added in v0.0.35
func (s GroupsService) Create(ctx context.Context, payload GroupPayload) (GroupResponse, error)
https://developer.zendesk.com/api-reference/ticketing/groups/groups/#create-group
func (GroupsService) List ¶ added in v0.0.12
func (s GroupsService) List( ctx context.Context, pageHandler func(response GroupsResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/groups/groups/#list-groups
func (GroupsService) Show ¶ added in v0.0.35
https://developer.zendesk.com/api-reference/ticketing/groups/groups/#show-group
type GuideService ¶
type GuideService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/help_center/help-center-api/introduction/
func (*GuideService) Articles ¶
func (s *GuideService) Articles() *ArticleService
https://developer.zendesk.com/api-reference/help_center/help-center-api/articles/
func (*GuideService) Categories ¶
func (s *GuideService) Categories() *CategoryService
https://developer.zendesk.com/api-reference/help_center/help-center-api/categories/
func (*GuideService) Sections ¶
func (s *GuideService) Sections() *SectionService
https://developer.zendesk.com/api-reference/help_center/help-center-api/sections/
type IdentityID ¶ added in v0.0.38
type IdentityID uint64
type IncrementalExportChat ¶ added in v0.0.2
type IncrementalExportChat struct { Chat ChatEngagements []ChatEngagement `json:"engagements"` }
type IncrementalExportResponse ¶
type IncrementalExportResponse struct { EndTimeUnix int64 `json:"end_time"` EndOfStream bool `json:"end_of_stream"` }
func (IncrementalExportResponse) EndTime ¶
func (response IncrementalExportResponse) EndTime() time.Time
type JobStatusResponse ¶ added in v0.0.22
type JobStatusResponse struct {
JobStatus JobStatus `json:"job_status"`
}
type ListAccountConfigurationAuditLogModifier ¶ added in v0.0.21
type ListAccountConfigurationAuditLogModifier interface {
ModifyListAccountConfigurationAuditLogRequest(queryParameters *url.Values)
}
https://developer.zendesk.com/api-reference/ticketing/account-configuration/audit_logs/#parameters
type ListProblemTicketIncidentsResponse ¶ added in v0.0.35
type ListProblemTicketIncidentsResponse struct { Tickets []Ticket `json:"tickets"` CursorPaginationResponse }
type LiveChatService ¶ added in v0.0.12
type LiveChatService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/live-chat/introduction/
func (*LiveChatService) AgentEvent ¶ added in v0.0.12
func (s *LiveChatService) AgentEvent() *AgentEventService
https://developer.zendesk.com/api-reference/live-chat/chat-api/incremental_agent_events_api/
func (*LiveChatService) Chat ¶ added in v0.0.12
func (s *LiveChatService) Chat() *ChatService
https://developer.zendesk.com/api-reference/live-chat/chat-api/chats/
type MalwareScanResult ¶ added in v0.0.37
type MalwareScanResult string
const ( MalwareFound MalwareScanResult = "malware_found" MalwareNotFound MalwareScanResult = "malware_not_found" MalwareFailedToScan MalwareScanResult = "failed_to_scan" MalwareNotScanned MalwareScanResult = "not_scanned" )
type MergeRequestPayload ¶ added in v0.0.22
type OffsetPaginationResponse ¶ added in v0.0.35
type OffsetPaginationResponse struct { NextPage *string `json:"next_page"` PreviousPage *string `json:"previous_page"` Count uint64 `json:"count"` }
https://developer.zendesk.com/api-reference/introduction/pagination/#using-offset-pagination
type Organization ¶
type Organization struct { ID OrganizationID `json:"id"` CreatedAt time.Time `json:"created_at"` DeletedAt *time.Time `json:"deleted_at"` Details string `json:"details"` DomainNames []string `json:"domain_names"` ExternalID *string `json:"external_id"` GroupID *GroupID `json:"group_id"` Name string `json:"name"` Notes string `json:"notes"` Tags []Tag `json:"tags"` UpdatedAt time.Time `json:"updated_at"` OrganizationFields OrganizationFields `json:"organization_fields"` }
type OrganizationAutocompleteResponse ¶ added in v0.0.38
type OrganizationAutocompleteResponse struct { Organizations []Organization `json:"organizations"` OffsetPaginationResponse }
type OrganizationFieldConfiguration ¶ added in v0.0.37
type OrganizationFieldConfiguration struct { Active bool `json:"active"` CreatedAt time.Time `json:"created_at"` CustomFieldOptions []CustomFieldOption `json:"custom_field_options"` Description string `json:"description"` ID OrganizationFieldID `json:"id"` Key string `json:"key"` Position uint64 `json:"position"` RawDescription string `json:"raw_description"` RawTitle string `json:"raw_title"` RegexpForValidation *string `json:"regexp_for_validation"` System bool `json:"system"` Tag Tag `json:"tag"` Title string `json:"title"` Type OrganizationFieldType `json:"type"` UpdatedAt time.Time `json:"updated_at"` URL string `json:"url"` }
https://developer.zendesk.com/api-reference/ticketing/organizations/organization_fields/#json-format
type OrganizationFieldConfigurationResponse ¶ added in v0.0.37
type OrganizationFieldConfigurationResponse struct {
OrganizationField OrganizationFieldConfiguration `json:"organization_field"`
}
type OrganizationFieldID ¶ added in v0.0.35
type OrganizationFieldID uint64
type OrganizationFieldPayload ¶ added in v0.0.35
type OrganizationFieldPayload struct {
OrganizationField any `json:"organization_field"`
}
type OrganizationFieldService ¶ added in v0.0.35
type OrganizationFieldService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/organizations/organization_fields/
func (OrganizationFieldService) Create ¶ added in v0.0.35
func (s OrganizationFieldService) Create(ctx context.Context, payload OrganizationFieldPayload) (OrganizationFieldConfigurationResponse, error)
func (OrganizationFieldService) Delete ¶ added in v0.0.35
func (s OrganizationFieldService) Delete(ctx context.Context, id OrganizationFieldID) error
func (OrganizationFieldService) List ¶ added in v0.0.35
func (s OrganizationFieldService) List( ctx context.Context, pageHandler func(response OrganizationFieldsConfigurationResponse) error, ) error
func (OrganizationFieldService) Show ¶ added in v0.0.35
func (s OrganizationFieldService) Show(ctx context.Context, id OrganizationFieldID) (OrganizationFieldConfiguration, error)
func (OrganizationFieldService) Update ¶ added in v0.0.35
func (s OrganizationFieldService) Update( ctx context.Context, id OrganizationFieldID, payload OrganizationFieldPayload, ) (OrganizationFieldConfigurationResponse, error)
type OrganizationFieldType ¶ added in v0.0.37
type OrganizationFieldType string
const ( OrganizationFieldTypeText OrganizationFieldType = "text" // Default custom field type when type is not specified OrganizationFieldTypeTextArea OrganizationFieldType = "textarea" // For multi-line text OrganizationFieldTypeCheckbox OrganizationFieldType = "checkbox" // To capture a boolean value. Allowed values are true or false OrganizationFieldTypeDate OrganizationFieldType = "date" // Example: 2021-04-16 OrganizationFieldTypeDropdown OrganizationFieldType = "dropdown" // OrganizationFieldTypeInteger OrganizationFieldType = "integer" // String composed of numbers. May contain an optional decimal point OrganizationFieldTypeDecimal OrganizationFieldType = "decimal" // For numbers containing decimals OrganizationFieldTypeRegexp OrganizationFieldType = "regexp" // Matches the Regex pattern found in the custom field settings OrganizationFieldTypeLookup OrganizationFieldType = "lookup" // A field to create a relationship to another object such as a user, ticket, or organization )
type OrganizationFields ¶ added in v0.0.12
NOTE: Organization Fields are returned as a map[string (name of field)]any (value of field), instead of the way in which Ticket Fields are returned.
func (OrganizationFields) GetBool ¶ added in v0.0.12
func (fields OrganizationFields) GetBool(key string) bool
func (OrganizationFields) GetString ¶ added in v0.0.12
func (fields OrganizationFields) GetString(key string) *string
type OrganizationFieldsConfigurationResponse ¶ added in v0.0.37
type OrganizationFieldsConfigurationResponse struct { OrganizationFields []OrganizationFieldConfiguration `json:"organization_fields"` CursorPaginationResponse }
type OrganizationID ¶
type OrganizationID uint64
type OrganizationMembership ¶ added in v0.0.38
type OrganizationMembership struct { CreatedAt time.Time `json:"created_at"` Default bool `json:"default"` ID OrganizationMembershipID `json:"id"` OrganizationID OrganizationID `json:"organization_id"` OrganizationName string `json:"organization_name"` UpdatedAt *time.Time `json:"updated_at"` URL string `json:"url"` UserID UserID `json:"user_id"` ViewTickets bool `json:"view_tickets"` }
type OrganizationMembershipID ¶ added in v0.0.38
type OrganizationMembershipID uint64
type OrganizationMembershipPayload ¶ added in v0.0.38
type OrganizationMembershipPayload struct {
OrganizationMembership OrganizationMembershipPayloadData `json:"organization_membership"`
}
type OrganizationMembershipPayloadData ¶ added in v0.0.38
type OrganizationMembershipPayloadData struct { UserID UserID `json:"user_id"` OrganizationID OrganizationID `json:"organization_id"` }
type OrganizationMembershipResponse ¶ added in v0.0.38
type OrganizationMembershipResponse struct {
OrganizationMembership OrganizationMembership `json:"organization_membership"`
}
type OrganizationMembershipService ¶ added in v0.0.38
type OrganizationMembershipService struct {
// contains filtered or unexported fields
}
func (OrganizationMembershipService) Create ¶ added in v0.0.38
func (s OrganizationMembershipService) Create( ctx context.Context, payload OrganizationMembershipPayload, ) (OrganizationMembershipResponse, error)
func (OrganizationMembershipService) List ¶ added in v0.0.38
func (s OrganizationMembershipService) List( ctx context.Context, pageHandler func(response OrganizationMembershipsResponse) error, ) error
func (OrganizationMembershipService) Show ¶ added in v0.0.38
func (s OrganizationMembershipService) Show( ctx context.Context, id OrganizationMembershipID, ) (OrganizationMembership, error)
type OrganizationMembershipsResponse ¶ added in v0.0.38
type OrganizationMembershipsResponse struct { OrganizationMemberships []OrganizationMembership `json:"organization_memberships"` CursorPaginationResponse }
type OrganizationPayload ¶ added in v0.0.12
type OrganizationPayload struct {
Organization any `json:"organization"`
}
type OrganizationResponse ¶
type OrganizationResponse struct {
Organization Organization `json:"organization"`
}
type OrganizationSatisfactionRating ¶
type OrganizationSatisfactionRating struct {
Score string `json:"score"`
}
type OrganizationService ¶
type OrganizationService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/organizations/organizations/
func (OrganizationService) Autocomplete ¶ added in v0.0.38
func (s OrganizationService) Autocomplete( ctx context.Context, term string, pageHandler func(response OrganizationAutocompleteResponse) error, ) error
Does not support cursor pagination.
func (OrganizationService) Create ¶ added in v0.0.12
func (s OrganizationService) Create(ctx context.Context, payload OrganizationPayload) (OrganizationResponse, error)
func (OrganizationService) IncrementalExport ¶
func (s OrganizationService) IncrementalExport( ctx context.Context, startTime int64, pageHandler func(response OrganizationsIncrementalExportResponse) error, ) error
func (OrganizationService) Show ¶
func (s OrganizationService) Show(ctx context.Context, id OrganizationID) (Organization, error)
https://developer.zendesk.com/api-reference/ticketing/organizations/organizations/#show-organization
func (OrganizationService) Update ¶ added in v0.0.12
func (s OrganizationService) Update(ctx context.Context, id OrganizationID, payload OrganizationPayload) (OrganizationResponse, error)
type OrganizationVia ¶
type OrganizationVia struct {
Channel string `json:"channel"`
}
type OrganizationsIncrementalExportResponse ¶
type OrganizationsIncrementalExportResponse struct { OrganizationsResponse IncrementalExportResponse }
type OrganizationsResponse ¶
type OrganizationsResponse struct {
Organizations []Organization `json:"organizations"`
}
type PermissionGroupID ¶ added in v0.0.12
type PermissionGroupID uint64
type ReasonCode ¶ added in v0.0.43
type ReasonCode uint64
type RequestPreProcessor ¶
type RequestPreProcessorFunc ¶
func (RequestPreProcessorFunc) ProcessRequest ¶
func (p RequestPreProcessorFunc) ProcessRequest(r *http.Request) error
type SatisfactionRating ¶ added in v0.0.43
type SatisfactionRating struct { ID SatisfactionRatingID `json:"id"` AssigneeID *UserID `json:"assignee_id"` Comment *string `json:"comment"` CreatedAt time.Time `json:"created_at"` GroupID *GroupID `json:"group_id"` Reason *string `json:"reason"` ReasonCode *ReasonCode `json:"reason_code"` ReasonID *ReasonID `json:"reason_id"` RequesterID UserID `json:"requester_id"` Score string `json:"score"` TicketID TicketID `json:"ticket_id"` UpdatedAt *time.Time `json:"updated_at"` URL string `json:"url"` }
type SatisfactionRatingID ¶ added in v0.0.43
type SatisfactionRatingID uint64
type SatisfactionRatingResponse ¶ added in v0.0.43
type SatisfactionRatingResponse struct {
SatisfactionRating SatisfactionRating `json:"satisfaction_rating"`
}
type SatisfactionRatingScore ¶ added in v0.0.43
type SatisfactionRatingScore string
const ( SatisfactionRatingScoreOffered SatisfactionRatingScore = "offered" SatisfactionRatingScoreUnOffered SatisfactionRatingScore = "unoffered" SatisfactionRatingScoreGood SatisfactionRatingScore = "good" SatisfactionRatingScoreBad SatisfactionRatingScore = "bad" )
type SatisfactionRatingService ¶ added in v0.0.43
type SatisfactionRatingService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/ticket-management/satisfaction_ratings/
func (SatisfactionRatingService) List ¶ added in v0.0.43
func (s SatisfactionRatingService) List( ctx context.Context, pageHandler func(response SatisfactionRatingsResponse) error, ) error
func (SatisfactionRatingService) Show ¶ added in v0.0.43
func (s SatisfactionRatingService) Show(ctx context.Context, id SatisfactionRatingID) (SatisfactionRating, error)
type SatisfactionRatingsResponse ¶ added in v0.0.43
type SatisfactionRatingsResponse struct { SatisfactionRatings []SatisfactionRating `json:"satisfaction_ratings"` CursorPaginationResponse }
type Schedule ¶ added in v0.0.12
type Schedule struct { ID ScheduleID `json:"id"` Name string `json:"name"` TimeZone string `json:"time_zone"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` Intervals []ScheduleInterval `json:"intervals"` }
type ScheduleID ¶ added in v0.0.12
type ScheduleID uint64
type ScheduleInterval ¶ added in v0.0.12
type ScheduleService ¶ added in v0.0.12
type ScheduleService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/ticket-management/schedules/
func (*ScheduleService) List ¶ added in v0.0.12
func (s *ScheduleService) List( ctx context.Context, ) (SchedulesResponse, error)
https://developer.zendesk.com/api-reference/ticketing/ticket-management/schedules/#list-schedules
type SchedulesResponse ¶ added in v0.0.12
type SchedulesResponse struct {
Schedules []Schedule `json:"schedules"`
}
type Section ¶
type Section struct { CategoryID CategoryID `json:"category_id"` CreatedAt time.Time `json:"created_at"` Description string `json:"description"` HTMLURL string `json:"html_url"` ID SectionID `json:"id"` Locale string `json:"locale"` Name string `json:"name"` Outdated bool `json:"outdated"` ParentSectionID any `json:"parent_section_id"` Position uint `json:"position"` Sorting string `json:"sorting"` SourceLocale string `json:"source_locale"` ThemeTemplate string `json:"theme_template"` UpdatedAt time.Time `json:"updated_at"` URL string `json:"url"` }
type SectionService ¶ added in v0.0.12
type SectionService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/help_center/help-center-api/sections/
func (SectionService) List ¶ added in v0.0.26
func (s SectionService) List( ctx context.Context, pageHandler func(response SectionsResponse) error, ) error
type SectionsResponse ¶
type SectionsResponse struct { Sections []Section `json:"sections"` Page int `json:"page"` PreviousPage any `json:"previous_page"` NextPage string `json:"next_page"` PerPage int `json:"per_page"` PageCount int `json:"page_count"` Count int `json:"count"` SortBy string `json:"sort_by"` SortOrder string `json:"sort_order"` CursorPaginationResponse }
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
func NewService( subDomain string, zendeskAuth authentication, chatCredentials ChatCredentials, opts ...configOption, ) *Service
func (*Service) AccountConfiguration ¶ added in v0.0.21
func (s *Service) AccountConfiguration() *AccountConfigurationService
https://developer.zendesk.com/api-reference/ticketing/introduction/
func (*Service) Guide ¶
func (s *Service) Guide() *GuideService
https://developer.zendesk.com/api-reference/help_center/help-center-api/introduction/
func (*Service) LiveChat ¶ added in v0.0.12
func (s *Service) LiveChat() *LiveChatService
https://developer.zendesk.com/api-reference/live-chat/introduction/
func (*Service) Support ¶
func (s *Service) Support() *SupportService
https://developer.zendesk.com/api-reference/ticketing/introduction/
type SideConversationCreatePayload ¶ added in v0.0.30
type SideConversationCreatePayload struct {
Message SideConversationMessage `json:"message"`
}
type SideConversationMessage ¶ added in v0.0.30
type SideConversationMessage struct { Subject string `json:"subject"` Body string `json:"body"` To []SideConversationTarget `json:"to"` }
type SideConversationService ¶ added in v0.0.30
type SideConversationService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/side_conversation/side_conversation/
func (*SideConversationService) Create ¶ added in v0.0.30
func (s *SideConversationService) Create( ctx context.Context, ticketID TicketID, payload SideConversationCreatePayload, ) error
type SideConversationTarget ¶ added in v0.0.30
type SideConversationTarget interface {
SideConversationTarget()
}
type SideConversationTargetChildTicket ¶ added in v0.0.30
type SideConversationTargetChildTicket struct { SupportGroupID GroupID `json:"support_group_id"` SupportAgentID UserID `json:"support_agent_id,omitempty"` }
func (SideConversationTargetChildTicket) SideConversationTarget ¶ added in v0.0.30
func (s SideConversationTargetChildTicket) SideConversationTarget()
type SupportService ¶
type SupportService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/introduction/
func (*SupportService) CustomStatuses ¶ added in v0.0.35
func (s *SupportService) CustomStatuses() *CustomStatusService
https://developer.zendesk.com/api-reference/ticketing/organizations/organizations/
func (*SupportService) GroupMemberships ¶ added in v0.0.12
func (s *SupportService) GroupMemberships() *GroupMembershipService
https://developer.zendesk.com/api-reference/ticketing/groups/group_memberships/
func (*SupportService) Groups ¶ added in v0.0.12
func (s *SupportService) Groups() *GroupsService
https://developer.zendesk.com/api-reference/ticketing/groups/groups/
func (*SupportService) OrganizationFields ¶ added in v0.0.35
func (s *SupportService) OrganizationFields() *OrganizationFieldService
https://developer.zendesk.com/api-reference/ticketing/organizations/organizations/
func (*SupportService) OrganizationMemberships ¶ added in v0.0.38
func (s *SupportService) OrganizationMemberships() *OrganizationMembershipService
https://developer.zendesk.com/api-reference/ticketing/organizations/organizations/
func (*SupportService) Organizations ¶
func (s *SupportService) Organizations() *OrganizationService
https://developer.zendesk.com/api-reference/ticketing/organizations/organizations/
func (*SupportService) SatisfactionRatings ¶ added in v0.0.43
func (s *SupportService) SatisfactionRatings() *SatisfactionRatingService
https://developer.zendesk.com/api-reference/ticketing/ticket-management/satisfaction_ratings
func (*SupportService) Schedules ¶ added in v0.0.12
func (s *SupportService) Schedules() *ScheduleService
https://developer.zendesk.com/api-reference/ticketing/ticket-management/schedules/
func (*SupportService) SideConversations ¶ added in v0.0.30
func (s *SupportService) SideConversations() *SideConversationService
https://developer.zendesk.com/api-reference/ticketing/side_conversation/side_conversation/
func (*SupportService) SuspendedTickets ¶ added in v0.0.12
func (s *SupportService) SuspendedTickets() *SuspendedTicketService
https://developer.zendesk.com/api-reference/ticketing/tickets/suspended_tickets/
func (*SupportService) TicketAttachments ¶ added in v0.0.35
func (s *SupportService) TicketAttachments() *TicketAttachmentService
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket-attachments/
func (*SupportService) TicketAudits ¶ added in v0.0.12
func (s *SupportService) TicketAudits() *TicketAuditService
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_audits/
func (*SupportService) TicketComments ¶ added in v0.0.35
func (s *SupportService) TicketComments() *TicketCommentService
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_comments
func (*SupportService) TicketFields ¶ added in v0.0.35
func (s *SupportService) TicketFields() *TicketFieldService
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_fields
func (*SupportService) TicketForms ¶ added in v0.0.31
func (s *SupportService) TicketForms() *TicketFormService
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_forms/
func (*SupportService) TicketTags ¶ added in v0.0.43
func (s *SupportService) TicketTags() *TicketTagService
https://developer.zendesk.com/api-reference/ticketing/ticket-management/tags
func (*SupportService) Tickets ¶
func (s *SupportService) Tickets() *TicketService
https://developer.zendesk.com/api-reference/ticketing/tickets/tickets/
func (*SupportService) UserFields ¶ added in v0.0.12
func (s *SupportService) UserFields() *UserFieldService
https://developer.zendesk.com/api-reference/ticketing/users/user_fields/
func (*SupportService) UserIdentities ¶ added in v0.0.13
func (s *SupportService) UserIdentities() *UserIdentityService
https://developer.zendesk.com/api-reference/ticketing/users/user_identities/
func (*SupportService) Users ¶
func (s *SupportService) Users() *UserService
https://developer.zendesk.com/api-reference/ticketing/users/users/
type SuspendedTicket ¶ added in v0.0.12
type SuspendedTicket struct { ID SuspendedTicketID `json:"id"` Subject string `json:"subject"` Cause string `json:"cause"` CauseID int `json:"cause_id"` TicketID *TicketID `json:"ticket_id"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` Recipient string `json:"recipient"` }
type SuspendedTicketID ¶ added in v0.0.12
type SuspendedTicketID uint64
type SuspendedTicketService ¶ added in v0.0.12
type SuspendedTicketService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/suspended_tickets/
func (*SuspendedTicketService) Delete ¶ added in v0.0.12
func (s *SuspendedTicketService) Delete(ctx context.Context, id SuspendedTicketID) error
func (SuspendedTicketService) List ¶ added in v0.0.12
func (s SuspendedTicketService) List( ctx context.Context, pageHandler func(response SuspendedTicketsResponse) error, ) error
func (*SuspendedTicketService) RecoverMultiple ¶ added in v0.0.12
func (s *SuspendedTicketService) RecoverMultiple(ctx context.Context, ids []SuspendedTicketID) error
type SuspendedTicketsResponse ¶ added in v0.0.12
type SuspendedTicketsResponse struct { SuspendedTickets []SuspendedTicket `json:"suspended_tickets"` CursorPaginationResponse }
type TagSearchResponse ¶ added in v0.0.37
type TagSearchResponse struct { Tags []Tag `json:"tags"` OffsetPaginationResponse }
type TagsPayload ¶
type TagsPayload struct {
Tags Tags `json:"tags"`
}
type TagsResponse ¶ added in v0.0.37
type TagsResponse struct { Tags []TagMeta `json:"tags"` CursorPaginationResponse }
type Ticket ¶
type Ticket struct { AssigneeID *UserID `json:"assignee_id"` CreatedAt time.Time `json:"created_at"` CollaboratorIDs []UserID `json:"collaborator_ids"` CustomFields []TicketField `json:"custom_fields"` Description string `json:"description"` DueAt *time.Time `json:"due_at"` ExternalID *string `json:"external_id"` Fields []TicketField `json:"fields"` FollowerIDs []UserID `json:"follower_ids"` GroupID *GroupID `json:"group_id"` HasIncidents bool `json:"has_incidents"` ID TicketID `json:"id"` IsPublic bool `json:"is_public"` OrganizationID *OrganizationID `json:"organization_id"` Priority string `json:"priority"` ProblemID *TicketID `json:"problem_id"` RequesterID UserID `json:"requester_id"` SatisfactionRating TicketSatisfactionRating `json:"satisfaction_rating"` Status string `json:"status"` Subject string `json:"subject"` SubmitterID UserID `json:"submitter_id"` Tags Tags `json:"tags"` TicketFormID TicketFormID `json:"ticket_form_id"` Type *string `json:"type"` UpdatedAt time.Time `json:"updated_at"` URL string `json:"url"` Via TicketVia `json:"via"` Dates TicketDates `json:"dates"` }
type TicketAttachment ¶ added in v0.0.35
type TicketAttachment struct { ContentType string `json:"content_type"` ContentURL string `json:"content_url"` Deleted bool `json:"deleted"` FileName string `json:"file_name"` Height uint64 `json:"height"` ID AttachmentID `json:"id"` Inline bool `json:"inline"` MalwareAccessOverride bool `json:"malware_access_override"` MalwareScanResult MalwareScanResult `json:"malware_scan_result"` MappedContentURL string `json:"mapped_content_url"` Size uint64 `json:"size"` URL string `json:"url"` Width uint64 `json:"width"` }
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket-attachments/#json-format
type TicketAttachmentResponse ¶ added in v0.0.35
type TicketAttachmentResponse struct {
Attachment TicketAttachment `json:"attachment"`
}
type TicketAttachmentService ¶ added in v0.0.35
type TicketAttachmentService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket-attachments/
func (TicketAttachmentService) Download ¶ added in v0.0.37
func (s TicketAttachmentService) Download( ctx context.Context, contentURL string, writer io.Writer, ) error
When working with attachments, we must ensure that the domain that the content is hosted on is *.zendesk.com before sending authentication credentials.
- https://developer.zendesk.com/documentation/ticketing/managing-tickets/working-with-url-properties/
- https://developer.zendesk.com/api-reference/ticketing/tickets/ticket-attachments/#json-format
func (*TicketAttachmentService) DownloadToFile ¶ added in v0.0.37
func (TicketAttachmentService) Show ¶ added in v0.0.35
func (s TicketAttachmentService) Show( ctx context.Context, attachmentID AttachmentID, ) (TicketAttachment, error)
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket-attachments/#show-attachment
func (TicketAttachmentService) Upload ¶ added in v0.0.35
func (s TicketAttachmentService) Upload( ctx context.Context, localFilePath string, uploadToken UploadToken, ) (TicketAttachmentUploadResponse, error)
func (TicketAttachmentService) UploadWithFilename ¶ added in v0.0.39
func (s TicketAttachmentService) UploadWithFilename( ctx context.Context, localFilePath string, filename string, uploadToken UploadToken, ) (TicketAttachmentUploadResponse, error)
type TicketAttachmentUploadResponse ¶ added in v0.0.35
type TicketAttachmentUploadResponse struct { Upload struct { Attachment TicketAttachment `json:"attachment"` Attachments []TicketAttachment `json:"attachments"` Token UploadToken `json:"token"` } `json:"upload"` }
type TicketAudit ¶ added in v0.0.12
type TicketAudit struct { ID TicketAuditID `json:"id"` TicketID int `json:"ticket_id"` CreatedAt time.Time `json:"created_at"` AuthorID int `json:"author_id"` Events []TicketAuditEvent `json:"events"` }
type TicketAuditEvent ¶ added in v0.0.12
type TicketAuditEvent struct { ID TicketAuditEventID `json:"id"` Type string `json:"type"` FieldName string `json:"field_name"` PreviousValue any `json:"previous_value"` Value any `json:"value"` }
type TicketAuditEventID ¶ added in v0.0.12
type TicketAuditEventID uint64
type TicketAuditID ¶ added in v0.0.12
type TicketAuditID uint64
type TicketAuditResponse ¶ added in v0.0.12
type TicketAuditResponse struct {
Audit TicketAudit `json:"audit"`
}
type TicketAuditService ¶ added in v0.0.12
type TicketAuditService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_audits/
func (TicketAuditService) ListForTicket ¶ added in v0.0.12
func (s TicketAuditService) ListForTicket( ctx context.Context, ticketID TicketID, pageHandler func(response TicketAuditsResponse) error, ) error
type TicketAuditsResponse ¶ added in v0.0.12
type TicketAuditsResponse struct { Audits []TicketAudit `json:"audits"` CursorPaginationResponse }
type TicketComment ¶ added in v0.0.35
type TicketComment struct { ID TicketCommentID `json:"id"` Attachments []TicketAttachment `json:"attachments"` AuditID AuditID `json:"audit_id"` AuthorID UserID `json:"author_id"` Body string `json:"body"` CreatedAt time.Time `json:"created_at"` HTMLBody string `json:"html_body"` Metadata TicketCommentMetadata `json:"metadata"` PlainBody string `json:"plain_body"` Public bool `json:"public"` Type string `json:"type"` Uploads []UploadToken `json:"uploads"` }
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_comments/#json-format
type TicketCommentID ¶ added in v0.0.35
type TicketCommentID uint64
type TicketCommentMetadata ¶ added in v0.0.37
type TicketCommentMetadata struct { System TicketCommentMetadataSystem `json:"system"` Via TicketVia `json:"via"` Flags []uint `json:"flags"` // https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_comments/#comment-flags }
type TicketCommentMetadataSystem ¶ added in v0.0.37
type TicketCommentResponse ¶ added in v0.0.35
type TicketCommentResponse struct { Comments []TicketComment `json:"comments"` Users []User `json:"users"` CursorPaginationResponse }
type TicketCommentService ¶ added in v0.0.35
type TicketCommentService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_comments/
func (TicketCommentService) ListByTicketID ¶ added in v0.0.35
func (s TicketCommentService) ListByTicketID( ctx context.Context, ticketID TicketID, pageHandler func(response TicketCommentResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_comments/#list-comments
func (TicketCommentService) ListByTicketIDWithSideload ¶ added in v0.0.38
func (s TicketCommentService) ListByTicketIDWithSideload( ctx context.Context, ticketID TicketID, sideloads []TicketCommentSideload, pageHandler func(response TicketCommentResponse) error, ) error
type TicketCommentSideload ¶ added in v0.0.38
type TicketCommentSideload string
const (
TicketCommentSideloadUsers TicketCommentSideload = "users"
)
type TicketDates ¶ added in v0.0.39
type TicketDates struct { AssigneeUpdatedAt *time.Time `json:"assignee_updated_at"` RequesterUpdatedAt *time.Time `json:"requester_updated_at"` StatusUpdatedAt *time.Time `json:"status_updated_at"` InitiallyAssignedAt *time.Time `json:"initially_updated_at"` AssignedAt *time.Time `json:"assigned_updated_at"` SolvedAt *time.Time `json:"solved_updated_at"` LatestCommentAddedAt *time.Time `json:"latest_comment_added_at"` }
type TicketField ¶ added in v0.0.35
type TicketField struct { ID TicketFieldID `json:"id"` Value any `json:"value"` }
type TicketFieldConfiguration ¶ added in v0.0.37
type TicketFieldConfiguration struct { Active bool `json:"active"` AgentDescription string `json:"agent_description"` CollapsedForAgents bool `json:"collapsed_for_agents"` CreatedAt time.Time `json:"created_at"` CustomFieldOptions []CustomFieldOption `json:"custom_field_options"` CustomStatuses []CustomStatus `json:"custom_statuses"` Description string `json:"description"` EditableInPortal bool `json:"editable_in_portal"` ID TicketFieldID `json:"id"` Position uint64 `json:"position"` RawDescription string `json:"raw_description"` RawTitle string `json:"raw_title"` RawTitleInPortal string `json:"raw_title_in_portal"` RegexpForValidation *string `json:"regexp_for_validation"` Removable bool `json:"removable"` Required bool `json:"required"` RequiredInPortal bool `json:"required_in_portal"` Tag Tag `json:"tag"` Title string `json:"title"` TitleInPortal string `json:"title_in_portal"` Type TicketFieldType `json:"type"` UpdatedAt time.Time `json:"updated_at"` URL string `json:"url"` VisibleInPortal bool `json:"visible_in_portal"` }
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_fields/#json-format
type TicketFieldConfigurationResponse ¶ added in v0.0.37
type TicketFieldConfigurationResponse struct {
TicketField TicketFieldConfiguration `json:"ticket_field"`
}
type TicketFieldID ¶ added in v0.0.12
type TicketFieldID uint64
type TicketFieldService ¶ added in v0.0.35
type TicketFieldService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_fields/
func (TicketFieldService) List ¶ added in v0.0.35
func (s TicketFieldService) List( ctx context.Context, pageHandler func(response TicketFieldsConfigurationResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_fields/#list-ticket-fields
func (TicketFieldService) Show ¶ added in v0.0.35
func (s TicketFieldService) Show(ctx context.Context, id TicketFieldID) (TicketFieldConfiguration, error)
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_fields/#show-ticket-field
type TicketFieldType ¶ added in v0.0.37
type TicketFieldType string
const ( TicketFieldTypeText TicketFieldType = "text" // Default custom field type when type is not specified TicketFieldTypeTextArea TicketFieldType = "textarea" // For multi-line text TicketFieldTypeCheckbox TicketFieldType = "checkbox" // To capture a boolean value. Allowed values are true or false TicketFieldTypeDate TicketFieldType = "date" // Example: 2021-04-16 TicketFieldTypeInteger TicketFieldType = "integer" // String composed of numbers. May contain an optional decimal point TicketFieldTypeDecimal TicketFieldType = "decimal" // For numbers containing decimals TicketFieldTypeRegexp TicketFieldType = "regexp" // Matches the Regex pattern found in the custom field settings TicketFieldTypePartialCreditCard TicketFieldType = "partialcreditcard" // A credit card number. Only the last 4 digits are retained TicketFieldTypeMultiSelect TicketFieldType = "multiselect" // Enables users to choose multiple options from a dropdown menu TicketFieldTypeTagger TicketFieldType = "tagger" // Single-select dropdown menu. It contains one or more tag values belonging to the field's options. Example: ( {"id": 21938362, "value": ["hd_3000", "hd_5555"]}) TicketFieldTypeLookup TicketFieldType = "lookup" // A field to create a relationship to another object such as a user, ticket, or organization )
type TicketFields ¶ added in v0.0.37
type TicketFields []TicketField
func (TicketFields) CreateMap ¶ added in v0.0.37
func (fields TicketFields) CreateMap() map[TicketFieldID]any
type TicketFieldsConfigurationResponse ¶ added in v0.0.37
type TicketFieldsConfigurationResponse struct { TicketFields []TicketFieldConfiguration `json:"ticket_fields"` CursorPaginationResponse }
type TicketForm ¶ added in v0.0.31
type TicketForm struct { URL string `json:"url"` Name string `json:"name"` DisplayName string `json:"display_name"` ID TicketFormID `json:"id"` RawName string `json:"raw_name"` RawDisplayName string `json:"raw_display_name"` EndUserVisible bool `json:"end_user_visible"` Position int `json:"position"` TicketFieldIds []TicketFieldID `json:"ticket_field_ids"` Active bool `json:"active"` Default bool `json:"default"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` InAllBrands bool `json:"in_all_brands"` }
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_forms/#json-format
type TicketFormID ¶
type TicketFormID uint64
type TicketFormResponse ¶ added in v0.0.35
type TicketFormResponse struct {
TicketForm TicketForm `json:"ticket_form"`
}
type TicketFormService ¶ added in v0.0.31
type TicketFormService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_forms/
func (TicketFormService) List ¶ added in v0.0.31
func (s TicketFormService) List( ctx context.Context, ) ([]TicketForm, error)
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_forms/#list-ticket-forms
Does not support pagination.
func (TicketFormService) Show ¶ added in v0.0.35
func (s TicketFormService) Show( ctx context.Context, ticketFormID TicketFormID, ) (TicketForm, error)
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_forms/#show-ticket-form
type TicketFormsResponse ¶ added in v0.0.31
type TicketFormsResponse struct {
TicketForms []TicketForm `json:"ticket_forms"`
}
type TicketPayload ¶ added in v0.0.12
type TicketPayload struct {
Ticket any `json:"ticket"`
}
type TicketResponse ¶
type TicketResponse struct {
Ticket Ticket `json:"ticket"`
}
type TicketSatisfactionRating ¶
type TicketSatisfactionRating struct {
Score string `json:"score"`
}
type TicketService ¶
type TicketService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/tickets/tickets/
func (TicketService) AddTags ¶
https://developer.zendesk.com/api-reference/ticketing/ticket-management/tags/#add-tags
func (TicketService) Create ¶ added in v0.0.12
func (s TicketService) Create(ctx context.Context, payload TicketPayload) (TicketResponse, error)
https://developer.zendesk.com/api-reference/ticketing/tickets/tickets/#create-ticket
func (TicketService) Import ¶ added in v0.0.39
func (s TicketService) Import(ctx context.Context, payload TicketPayload) (TicketResponse, error)
https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_import/#ticket-import
func (TicketService) IncrementalExport ¶
func (s TicketService) IncrementalExport( ctx context.Context, startTime time.Time, perPage uint, pageHandler func(response TicketsIncrementalExportResponse) error, ) error
func (TicketService) IncrementalExportWithSideloads ¶ added in v0.0.39
func (s TicketService) IncrementalExportWithSideloads( ctx context.Context, startTime time.Time, sideloads []TicketSideload, perPage uint, pageHandler func(response TicketsIncrementalExportResponse) error, ) error
func (TicketService) ListProblemTicketIncidents ¶ added in v0.0.35
func (s TicketService) ListProblemTicketIncidents( ctx context.Context, problemTicket TicketID, pageHandler func(response ListProblemTicketIncidentsResponse) error, ) error
func (TicketService) Merge ¶ added in v0.0.22
func (s TicketService) Merge(ctx context.Context, destination TicketID, payload MergeRequestPayload) (JobStatusResponse, error)
func (TicketService) RemoveTags ¶
https://developer.zendesk.com/api-reference/ticketing/ticket-management/tags/#remove-tags
func (TicketService) SetTags ¶
https://developer.zendesk.com/api-reference/ticketing/ticket-management/tags/#set-tags
func (TicketService) Show ¶
https://developer.zendesk.com/api-reference/ticketing/tickets/tickets/#show-ticket
func (TicketService) Update ¶ added in v0.0.12
func (s TicketService) Update(ctx context.Context, id TicketID, payload TicketPayload) (TicketResponse, error)
https://developer.zendesk.com/api-reference/ticketing/tickets/tickets/#update-ticket
type TicketSideload ¶ added in v0.0.39
type TicketSideload string
const (
TicketSideloadDates TicketSideload = "dates"
)
type TicketTagService ¶ added in v0.0.37
type TicketTagService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/ticket-management/tags
func (TicketTagService) List ¶ added in v0.0.37
func (s TicketTagService) List( ctx context.Context, pageHandler func(response TagsResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/ticket-management/tags/#list-tags
func (TicketTagService) Search ¶ added in v0.0.37
func (s TicketTagService) Search( ctx context.Context, searchTerm string, pageHandler func(response TagSearchResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/ticket-management/tags/#search-tags
Does not support cursor pagination.
type TicketsIncrementalExportResponse ¶
type TicketsIncrementalExportResponse struct { TicketsResponse IncrementalExportResponse }
type TicketsResponse ¶
type TicketsResponse struct {
Tickets []Ticket `json:"tickets"`
}
type UploadToken ¶ added in v0.0.35
type UploadToken string
type User ¶
type User struct { ID UserID `json:"id"` Active bool `json:"active"` Alias *string `json:"alias"` OnlyPrivateComments bool `json:"only_private_comments"` CreatedAt time.Time `json:"created_at"` CustomRoleID *CustomRoleID `json:"custom_role_id"` DefaultGroupID *GroupID `json:"default_group_id"` Details *string `json:"details"` Email string `json:"email"` ExternalID *string `json:"external_id"` IanaTimeZone string `json:"iana_time_zone"` TimeZone string `json:"time_zone"` LastLoginAt *time.Time `json:"last_login_at"` Locale string `json:"locale"` Name string `json:"name"` Notes *string `json:"notes"` OrganizationID *OrganizationID `json:"organization_id"` Phone *string `json:"phone"` RemotePhotoURL *string `json:"remote_photo_url"` RestrictedAgent bool `json:"restricted_agent"` Role UserRole `json:"role"` RoleType *int `json:"role_type"` Signature string `json:"signature"` Suspended bool `json:"suspended"` Tags []Tag `json:"tags"` TicketRestriction *UserTicketRestriction `json:"ticket_restriction"` TwoFactorAuthEnabled bool `json:"two_factor_auth_enabled"` UpdatedAt time.Time `json:"updated_at"` Verified bool `json:"verified"` UserFields UserFields `json:"user_fields"` Photo *UserPhoto `json:"photo"` }
https://developer.zendesk.com/api-reference/ticketing/users/users/#json-format
type UserFieldConfiguration ¶ added in v0.0.37
type UserFieldConfiguration struct { Active bool `json:"active"` CreatedAt time.Time `json:"created_at"` CustomFieldOptions []CustomFieldOption `json:"custom_field_options"` Description *string `json:"description"` ID UserFieldID `json:"id"` Key string `json:"key"` Position uint64 `json:"position"` RawDescription *string `json:"raw_description"` RawTitle *string `json:"raw_title"` RegexpForValidation *string `json:"regexp_for_validation"` System bool `json:"system"` Tag Tag `json:"tag"` Title *string `json:"title"` Type UserFieldType `json:"type"` UpdatedAt *time.Time `json:"updated_at"` URL string `json:"url"` }
https://developer.zendesk.com/api-reference/ticketing/users/user_fields/#json-format
type UserFieldConfigurationResponse ¶ added in v0.0.37
type UserFieldConfigurationResponse struct {
UserField UserFieldConfiguration `json:"user_field"`
}
type UserFieldID ¶ added in v0.0.12
type UserFieldID uint64
type UserFieldService ¶ added in v0.0.12
type UserFieldService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/users/user_fields/
func (UserFieldService) List ¶ added in v0.0.12
func (s UserFieldService) List( ctx context.Context, pageHandler func(response UserFieldsConfigurationResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/users/user_fields/#list-user-fields
func (UserFieldService) Show ¶ added in v0.0.35
func (s UserFieldService) Show( ctx context.Context, id UserFieldID, ) (UserFieldConfiguration, error)
type UserFieldType ¶ added in v0.0.37
type UserFieldType string
const ( UserFieldTypeText UserFieldType = "text" // Default custom field type when type is not specified UserFieldTypeTextArea UserFieldType = "textarea" // For multi-line text UserFieldTypeCheckbox UserFieldType = "checkbox" // To capture a boolean value. Allowed values are true or false UserFieldTypeDate UserFieldType = "date" // Example: 2021-04-16 UserFieldTypeDropdown UserFieldType = "dropdown" // UserFieldTypeInteger UserFieldType = "integer" // String composed of numbers. May contain an optional decimal point UserFieldTypeDecimal UserFieldType = "decimal" // For numbers containing decimals UserFieldTypeRegexp UserFieldType = "regexp" // Matches the Regex pattern found in the custom field settings UserFieldTypeLookup UserFieldType = "lookup" // A field to create a relationship to another object such as a user, ticket, or organization )
type UserFields ¶ added in v0.0.12
NOTE: User Fields are returned as a map[string (name of field)]any (value of field), instead of the way in which Ticket Fields are returned.
type UserFieldsConfigurationResponse ¶ added in v0.0.37
type UserFieldsConfigurationResponse struct { UserFields []UserFieldConfiguration `json:"user_fields"` CursorPaginationResponse }
type UserIdentitiesResponse ¶ added in v0.0.13
type UserIdentitiesResponse struct { Identities []UserIdentity `json:"identities"` CursorPaginationResponse }
type UserIdentity ¶ added in v0.0.13
type UserIdentity struct { URL string `json:"url"` UserID UserID `json:"user_id"` ID IdentityID `json:"id"` Type string `json:"type"` Verified bool `json:"verified"` Primary bool `json:"primary"` UndeliverableCount uint64 `json:"undeliverable_count"` DeliverableState string `json:"deliverable_state"` Value string `json:"value"` }
type UserIdentityPayload ¶ added in v0.0.38
type UserIdentityPayload struct {
Identity any `json:"identity"`
}
type UserIdentityResponse ¶ added in v0.0.38
type UserIdentityResponse struct {
Identity UserIdentity `json:"identity"`
}
type UserIdentityService ¶ added in v0.0.13
type UserIdentityService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/users/user_identities/
func (*UserIdentityService) Create ¶ added in v0.0.38
func (s *UserIdentityService) Create( ctx context.Context, userID UserID, payload UserIdentityPayload, ) (UserIdentityResponse, error)
https://developer.zendesk.com/api-reference/ticketing/users/user_identities/#create-identity
func (*UserIdentityService) List ¶ added in v0.0.13
func (s *UserIdentityService) List( ctx context.Context, userID UserID, pageHandler func(response UserIdentitiesResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/users/user_identities/#list-identities
type UserPayload ¶ added in v0.0.12
type UserPayload struct {
User any `json:"user"`
}
type UserResponse ¶
type UserResponse struct { User User `json:"user"` Identities []UserIdentity `json:"identities"` Organizations []Organization `json:"organizations"` }
type UserSearchResponse ¶ added in v0.0.38
type UserSearchResponse struct { Users []User `json:"users"` Identities []UserIdentity `json:"identities"` Organizations []Organization `json:"organizations"` Groups []Group `json:"groups"` OpenTicketCount map[string]uint64 `json:"open_ticket_count"` OffsetPaginationResponse }
type UserSegmentID ¶ added in v0.0.12
type UserSegmentID uint64
type UserService ¶
type UserService struct {
// contains filtered or unexported fields
}
https://developer.zendesk.com/api-reference/ticketing/users/users/
func (UserService) Create ¶ added in v0.0.12
func (s UserService) Create( ctx context.Context, payload UserPayload, ) (UserResponse, error)
https://developer.zendesk.com/api-reference/ticketing/users/users/#create-user
func (UserService) IncrementalExport ¶
func (s UserService) IncrementalExport( ctx context.Context, startTime int64, pageHandler func(response UsersIncrementalExportResponse) error, ) error
func (UserService) IncrementalExportWithSideloads ¶ added in v0.0.38
func (s UserService) IncrementalExportWithSideloads( ctx context.Context, startTime int64, sideloads []UserSideload, pageHandler func(response UsersIncrementalExportResponse) error, ) error
func (UserService) Search ¶ added in v0.0.12
func (s UserService) Search(ctx context.Context, query string) (UsersResponse, error)
https://developer.zendesk.com/api-reference/ticketing/users/users/#search-users
func (UserService) SearchWithSideloads ¶ added in v0.0.38
func (s UserService) SearchWithSideloads( ctx context.Context, query string, sideloads []UserSideload, pageHandler func(response UserSearchResponse) error, ) error
https://developer.zendesk.com/api-reference/ticketing/users/users/#search-users
Does not support cursor pagination.
func (UserService) Show ¶
https://developer.zendesk.com/api-reference/ticketing/users/users/#show-user
func (UserService) ShowSelf ¶ added in v0.0.12
func (s UserService) ShowSelf(ctx context.Context) (User, error)
https://developer.zendesk.com/api-reference/ticketing/users/users/#show-self
func (UserService) ShowWithSideloads ¶ added in v0.0.38
func (s UserService) ShowWithSideloads( ctx context.Context, id UserID, sideloads []UserSideload, ) (UserResponse, error)
https://developer.zendesk.com/api-reference/ticketing/users/users/#show-user
func (UserService) Update ¶ added in v0.0.12
func (s UserService) Update( ctx context.Context, id UserID, payload UserPayload, ) (UserResponse, error)
https://developer.zendesk.com/api-reference/ticketing/users/users/#update-user
type UserSideload ¶ added in v0.0.38
type UserSideload string
const ( UserSideloadIdentities UserSideload = "identities" UserSideloadOrganizations UserSideload = "organizations" UserSideloadRoles UserSideload = "roles" UserSideloadAbilities UserSideload = "abilities" UserSideloadGroups UserSideload = "groups" UserSideloadOpenTicketCount UserSideload = "open_ticket_count" )
type UserTicketRestriction ¶ added in v0.0.38
type UserTicketRestriction string
const ( UserTicketRestrictionOrganization UserTicketRestriction = "organization" UserTicketRestrictionGroups UserTicketRestriction = "groups" UserTicketRestrictionAssigned UserTicketRestriction = "assigned" UserTicketRestrictionRequested UserTicketRestriction = "requested" )
type UsersIncrementalExportResponse ¶
type UsersIncrementalExportResponse struct { UsersResponse IncrementalExportResponse }
type UsersResponse ¶
type UsersResponse struct {
Users []User `json:"users"`
}
Source Files ¶
- account_configuration.go
- account_configuration_audit_logs.go
- account_configuration_brand.go
- account_configuration_custom_roles.go
- authentication.go
- client.go
- config.go
- docs.go
- error.go
- guide.go
- guide_articles.go
- guide_categories.go
- guide_sections.go
- livechat.go
- livechat_agent_events.go
- livechat_chats.go
- pagination.go
- service.go
- support.go
- support_group.go
- support_group_memberships.go
- support_incremental_export.go
- support_job_statuses.go
- support_organization.go
- support_organization_field.go
- support_organization_membership.go
- support_satisfaction_rating.go
- support_schedules.go
- support_side_conversations.go
- support_suspended_ticket.go
- support_ticket_attachment.go
- support_ticket_audit.go
- support_ticket_comments.go
- support_ticket_custom_status.go
- support_ticket_field.go
- support_ticket_form.go
- support_ticket_management_tag.go
- support_tickets.go
- support_user_fields.go
- support_user_identities.go
- support_users.go
- types.go