Documentation ¶
Overview ¶
apiintegrations/apihandler/apihandler.go
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIHandler ¶
type APIHandler interface { ConstructAPIResourceEndpoint(endpointPath string, log logger.Logger) string ConstructAPIAuthEndpoint(endpointPath string, log logger.Logger) string MarshalRequest(body interface{}, method string, endpoint string, log logger.Logger) ([]byte, error) MarshalMultipartRequest(formFields map[string]string, fileContents map[string][]byte, log logger.Logger) ([]byte, string, string, error) GetContentTypeHeader(method string, log logger.Logger) string GetAcceptHeader() string GetDefaultBaseDomain() string GetOAuthTokenEndpoint() string GetOAuthTokenScope() string GetBearerTokenEndpoint() string GetTokenRefreshEndpoint() string GetTokenInvalidateEndpoint() string GetAPIBearerTokenAuthenticationSupportStatus() bool GetAPIOAuthAuthenticationSupportStatus() bool GetAPIOAuthWithCertAuthenticationSupportStatus() bool GetAPIRequestHeaders(endpoint string) map[string]string // Provides standard headers required for making API requests. }
APIHandler is an interface for encoding, decoding, and implenting contexual api functions for different API implementations. It encapsulates behavior for encoding and decoding requests and responses.
func LoadAPIHandler ¶
func LoadAPIHandler(apiType, instanceName, tenantID, tenantName string, log logger.Logger) (APIHandler, error)
LoadAPIHandler loads the appropriate API handler based on the API type.
Click to show internal directories.
Click to hide internal directories.