Versions in this module Expand all Collapse all v1 v1.0.10 Jan 20, 2023 v1.0.8 Sep 7, 2022 Changes in this version + const Accounts + const Activities + const AllMethod + const Approvals + const Calls + const Campaigns + const Cases + const Contacts + const Custom + const CustomButtons + const CustomLinks + const CustomViews + const Dashboards + const Deals + const Events + const FILE + const FILE_BYTE + const Fields + const Invoices + const JSON + const JSON_STRING + const Layouts + const Leads + const Macros + const Modules + const Notes + const PriceBooks + const Products + const Profiles + const PurchaseOrders + const Quotes + const RelatedLists + const Roles + const SalesOrders + const Search + const Solutions + const TabGroups + const Tasks + const Territories + const URL + const Vendors + var ErrClientSecretInvalidCode = errors.New("zoho: client secret used in authorization is invalid") + var ErrTokenExpired = errors.New("zoho: oAuth2 token already expired") + var ErrTokenInvalidCode = errors.New("zoho: authorization-code is invalid ") + var HTTPStatusCodes = map[HTTPStatusCode]string + func ResolveStatus(r *http.Response) string + type AccessTokenResponse struct + APIDomain string + AccessToken string + Error string + ExpiresIn int + RefreshToken string + TokenType string + type BodyFormat string + type DatastoreManager struct + EntityNamespace string + Request *http.Request + TokensKey string + func (d DatastoreManager) LoadAccessAndRefreshToken() (AccessTokenResponse, error) + func (d DatastoreManager) SaveTokens(t AccessTokenResponse) error + type Date time.Time + func (d *Date) MarshalJSON() ([]byte, error) + func (d *Date) UnmarshalJSON(b []byte) error + type Endpoint struct + Attachment string + AttachmentByte []byte + BodyFormat BodyFormat + Headers map[string]string + Method HTTPMethod + Name string + RequestBody interface{} + ResponseData interface{} + URL string + URLParameters map[string]Parameter + type HTTPHeader string + type HTTPMethod string + const HTTPDelete + const HTTPGet + const HTTPPost + const HTTPPut + type HTTPStatusCode int + type Method string + type ModulesMethod = Method + type OAuth struct + type Operation string + const All + const Create + const Delete + const NoOp + const Read + const Update + type Parameter string + type Scope string + const AdvanceScope + const ApprovalScope + const DataScope + const ExpenseReportScope + const FullAccessScope + const ModulesScope + const OrgScope + const ReimbursementScope + const SettingsScope + const UsersScope + type ScopeString string + func BuildScope(service Service, scope Scope, method Method, operation Operation) ScopeString + type Service string + const Bookings + const Crm + const Expense + type SettingsMethod = Method + type Time time.Time + func (t *Time) MarshalJSON() ([]byte, error) + func (t *Time) UnmarshalJSON(b []byte) error + type TokenLoaderSaver interface + LoadAccessAndRefreshToken func() (AccessTokenResponse, error) + SaveTokens func(t AccessTokenResponse) error + type TokenWrapper struct + Expires time.Time + Token AccessTokenResponse + func (t *TokenWrapper) CheckExpiry() bool + func (t *TokenWrapper) SetExpiry() + type Zoho struct + OrganizationID string + ZohoTLD string + func New() *Zoho + func (z *Zoho) AuthorizationCodeRequest(clientID, clientSecret string, scopes []ScopeString, redirectURI string) (err error) + func (z *Zoho) CheckForSavedTokens() error + func (z *Zoho) CustomHTTPClient(c *http.Client) + func (z *Zoho) GenerateTokenRequest(clientID, clientSecret, code, redirectURI string) (err error) + func (z *Zoho) GetOauthToken() string + func (z *Zoho) HTTPRequest(endpoint *Endpoint) (err error) + func (z *Zoho) RefreshTokenRequest() (err error) + func (z *Zoho) SetClientID(clientID string) + func (z *Zoho) SetClientSecret(clientSecret string) + func (z *Zoho) SetOrganizationID(orgID string) + func (z *Zoho) SetRefreshToken(refreshToken string) + func (z *Zoho) SetTokenManager(tm TokenLoaderSaver) + func (z *Zoho) SetTokensFile(s string) + func (z *Zoho) SetZohoTLD(s string) + func (z Zoho) LoadAccessAndRefreshToken() (AccessTokenResponse, error) + func (z Zoho) SaveTokens(t AccessTokenResponse) error