Documentation ¶
Index ¶
- Variables
- func CacheExpires(r *http.Response) time.Time
- type APIClient
- type APIKey
- type APIResponse
- type BasicAuth
- type Configuration
- type ConnectPostOpts
- type ConnectPutOpts
- type ConnectRequest
- type ConnectResponse
- type DefaultApiService
- func (a *DefaultApiService) ConnectPost(ctx _context.Context, userAgent string, xLicenseKey string, ...) (ConnectResponse, *_nethttp.Response, error)
- func (a *DefaultApiService) ConnectPut(ctx _context.Context, userAgent string, xLicenseKey string, ...) (ConnectResponse, *_nethttp.Response, error)
- func (a *DefaultApiService) DisconnectPut(ctx _context.Context, userAgent string, xLicenseKey string, ...) (*_nethttp.Response, error)
- func (a *DefaultApiService) LookupBatchPost(ctx _context.Context, userAgent string, xLicenseKey string, ...) ([]map[string]interface{}, *_nethttp.Response, error)
- func (a *DefaultApiService) LookupPost(ctx _context.Context, userAgent string, xLicenseKey string, ...) (LookupResponse, *_nethttp.Response, error)
- func (a *DefaultApiService) RegisterBatchPost(ctx _context.Context, userAgent string, xLicenseKey string, ...) ([]RegisterBatchEntityResponse, *_nethttp.Response, error)
- func (a *DefaultApiService) RegisterBatchPut(ctx _context.Context, userAgent string, xLicenseKey string, ...) ([]ReRegisterBatchEntityResponse, *_nethttp.Response, error)
- func (a *DefaultApiService) RegisterPost(ctx _context.Context, userAgent string, xLicenseKey string, ...) (RegisterResponse, *_nethttp.Response, error)
- func (a *DefaultApiService) RegisterPut(ctx _context.Context, userAgent string, xLicenseKey string, ...) (ReRegisterResponse, *_nethttp.Response, error)
- type DisconnectPutOpts
- type DisconnectRequest
- type Fingerprint
- type GenericOpenAPIError
- type Identity
- type LookupBatchPostOpts
- type LookupPostOpts
- type LookupRequest
- type LookupResponse
- type ReRegisterBatchEntityResponse
- type ReRegisterRequest
- type ReRegisterResponse
- type ReconnectRequest
- type RegisterBatchEntityResponse
- type RegisterBatchPostOpts
- type RegisterBatchPutOpts
- type RegisterPostOpts
- type RegisterPutOpts
- type RegisterRequest
- type RegisterResponse
- type ServerConfiguration
- type ServerVariable
Constants ¶
This section is empty.
Variables ¶
var ( // ContextOAuth2 takes an oauth2.TokenSource as authentication for the request. ContextOAuth2 = contextKey("token") // ContextBasicAuth takes BasicAuth as authentication for the request. ContextBasicAuth = contextKey("basic") // ContextAccessToken takes a string oauth2 access token as authentication for the request. ContextAccessToken = contextKey("accesstoken") // ContextAPIKey takes an APIKey as authentication for the request ContextAPIKey = contextKey("apikey") )
Functions ¶
Types ¶
type APIClient ¶
type APIClient struct { DefaultApi *DefaultApiService // contains filtered or unexported fields }
APIClient manages communication with the Identity API specifications API v1.5.0 In most cases there should be only one, shared, APIClient.
func NewAPIClient ¶
func NewAPIClient(cfg *Configuration) *APIClient
NewAPIClient creates a new API client. Requires a userAgent string describing your application. optionally a custom http.Client to allow for advanced features such as caching.
func (*APIClient) ChangeBasePath ¶
ChangeBasePath changes base path to allow switching to mocks
func (*APIClient) GetConfig ¶
func (c *APIClient) GetConfig() *Configuration
Allow modification of underlying config for alternate implementations and testing Caution: modifying the configuration while live can cause data races and potentially unwanted behavior
type APIKey ¶
APIKey provides API key based authentication to a request passed via context using ContextAPIKey
type APIResponse ¶
type APIResponse struct { *http.Response `json:"-"` Message string `json:"message,omitempty"` // Operation is the name of the OpenAPI operation. Operation string `json:"operation,omitempty"` // RequestURL is the request URL. This value is always available, even if the // embedded *http.Response is nil. RequestURL string `json:"url,omitempty"` // Method is the HTTP method used for the request. This value is always // available, even if the embedded *http.Response is nil. Method string `json:"method,omitempty"` // Payload holds the contents of the response body (which may be nil or empty). // This is provided here as the raw response.Body() reader will have already // been drained. Payload []byte `json:"-"` }
APIResponse stores the API response returned by the server.
func NewAPIResponse ¶
func NewAPIResponse(r *http.Response) *APIResponse
NewAPIResponse returns a new APIResonse object.
func NewAPIResponseWithError ¶
func NewAPIResponseWithError(errorMessage string) *APIResponse
NewAPIResponseWithError returns a new APIResponse object with the provided error message.
type BasicAuth ¶
type BasicAuth struct { UserName string `json:"userName,omitempty"` Password string `json:"password,omitempty"` }
BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth
type Configuration ¶
type Configuration struct { BasePath string `json:"basePath,omitempty"` Host string `json:"host,omitempty"` Scheme string `json:"scheme,omitempty"` DefaultHeader map[string]string `json:"defaultHeader,omitempty"` UserAgent string `json:"userAgent,omitempty"` Debug bool `json:"debug,omitempty"` Servers []ServerConfiguration HTTPClient *http.Client }
Configuration stores the configuration of the API client
func NewConfiguration ¶
func NewConfiguration() *Configuration
NewConfiguration returns a new Configuration object
func (*Configuration) AddDefaultHeader ¶
func (c *Configuration) AddDefaultHeader(key string, value string)
AddDefaultHeader adds a new HTTP header to the default header in the request
type ConnectPostOpts ¶
ConnectPostOpts Optional parameters for the method 'ConnectPost'
type ConnectPutOpts ¶
ConnectPutOpts Optional parameters for the method 'ConnectPut'
type ConnectRequest ¶
type ConnectRequest struct { Fingerprint Fingerprint `json:"fingerprint"` Metadata map[string]string `json:"metadata,omitempty"` Source string `json:"source,omitempty"` }
ConnectRequest struct for ConnectRequest
type ConnectResponse ¶
type ConnectResponse struct { Identity Identity `json:"identity"` Warnings []string `json:"warnings,omitempty"` }
ConnectResponse struct for ConnectResponse
type DefaultApiService ¶
type DefaultApiService service
DefaultApiService DefaultApi service
func (*DefaultApiService) ConnectPost ¶
func (a *DefaultApiService) ConnectPost(ctx _context.Context, userAgent string, xLicenseKey string, connectRequest ConnectRequest, localVarOptionals *ConnectPostOpts) (ConnectResponse, *_nethttp.Response, error)
ConnectPost Connect using a fingerprint
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param connectRequest
- @param optional nil or *ConnectPostOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
@return ConnectResponse
func (*DefaultApiService) ConnectPut ¶
func (a *DefaultApiService) ConnectPut(ctx _context.Context, userAgent string, xLicenseKey string, reconnectRequest ReconnectRequest, localVarOptionals *ConnectPutOpts) (ConnectResponse, *_nethttp.Response, error)
ConnectPut Reconnect using a fingerprint and an entityID
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param reconnectRequest
- @param optional nil or *ConnectPutOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
@return ConnectResponse
func (*DefaultApiService) DisconnectPut ¶
func (a *DefaultApiService) DisconnectPut(ctx _context.Context, userAgent string, xLicenseKey string, disconnectRequest DisconnectRequest, localVarOptionals *DisconnectPutOpts) (*_nethttp.Response, error)
DisconnectPut disconnects an entity
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param disconnectRequest
- @param optional nil or *DisconnectPutOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
func (*DefaultApiService) LookupBatchPost ¶
func (a *DefaultApiService) LookupBatchPost(ctx _context.Context, userAgent string, xLicenseKey string, lookupRequest []LookupRequest, localVarOptionals *LookupBatchPostOpts) ([]map[string]interface{}, *_nethttp.Response, error)
LookupBatchPost lookup batch for list of entities, given their entityNames
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param lookupRequest
- @param optional nil or *LookupBatchPostOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
@return []map[string]interface{}
func (*DefaultApiService) LookupPost ¶
func (a *DefaultApiService) LookupPost(ctx _context.Context, userAgent string, xLicenseKey string, lookupRequest LookupRequest, localVarOptionals *LookupPostOpts) (LookupResponse, *_nethttp.Response, error)
LookupPost lookup for an entity, given the entityName
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param lookupRequest
- @param optional nil or *LookupPostOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
@return LookupResponse
func (*DefaultApiService) RegisterBatchPost ¶
func (a *DefaultApiService) RegisterBatchPost(ctx _context.Context, userAgent string, xLicenseKey string, registerRequest []RegisterRequest, localVarOptionals *RegisterBatchPostOpts) ([]RegisterBatchEntityResponse, *_nethttp.Response, error)
RegisterBatchPost Register integration entities in batch of a max size of 1000 and 1MB
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param registerRequest
- @param optional nil or *RegisterBatchPostOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
- @param "XNRIAgentEntityId" (optional.Int64) -
@return []RegisterBatchEntityResponse
func (*DefaultApiService) RegisterBatchPut ¶
func (a *DefaultApiService) RegisterBatchPut(ctx _context.Context, userAgent string, xLicenseKey string, reRegisterRequest []ReRegisterRequest, localVarOptionals *RegisterBatchPutOpts) ([]ReRegisterBatchEntityResponse, *_nethttp.Response, error)
RegisterBatchPut Re-register integration entities in batch of a max size of 1000 and 1MB
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param reRegisterRequest
- @param optional nil or *RegisterBatchPutOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
- @param "XNRIAgentEntityId" (optional.Int64) -
@return []ReRegisterBatchEntityResponse
func (*DefaultApiService) RegisterPost ¶
func (a *DefaultApiService) RegisterPost(ctx _context.Context, userAgent string, xLicenseKey string, registerRequest RegisterRequest, localVarOptionals *RegisterPostOpts) (RegisterResponse, *_nethttp.Response, error)
RegisterPost Register integration entity
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param registerRequest
- @param optional nil or *RegisterPostOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
- @param "XNRIAgentEntityId" (optional.Int64) -
@return RegisterResponse
func (*DefaultApiService) RegisterPut ¶
func (a *DefaultApiService) RegisterPut(ctx _context.Context, userAgent string, xLicenseKey string, reRegisterRequest ReRegisterRequest, localVarOptionals *RegisterPutOpts) (ReRegisterResponse, *_nethttp.Response, error)
RegisterPut Re-register integration entity
- @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- @param userAgent
- @param xLicenseKey
- @param reRegisterRequest
- @param optional nil or *RegisterPutOpts - Optional Parameters:
- @param "ContentEncoding" (optional.String) -
- @param "XNRIAgentEntityId" (optional.Int64) -
@return ReRegisterResponse
type DisconnectPutOpts ¶
DisconnectPutOpts Optional parameters for the method 'DisconnectPut'
type DisconnectRequest ¶
DisconnectRequest struct for DisconnectRequest
type Fingerprint ¶
type Fingerprint struct { FullHostname string `json:"fullHostname,omitempty"` Hostname string `json:"hostname,omitempty"` CloudProviderId string `json:"cloudProviderId,omitempty"` DisplayName string `json:"displayName,omitempty"` BootId string `json:"bootId,omitempty"` IpAddresses map[string][]string `json:"ipAddresses,omitempty"` MacAddresses map[string][]string `json:"macAddresses,omitempty"` Type string `json:"type,omitempty"` }
Fingerprint struct for Fingerprint
type GenericOpenAPIError ¶
type GenericOpenAPIError struct {
// contains filtered or unexported fields
}
GenericOpenAPIError Provides access to the body, error and model on returned errors.
func (GenericOpenAPIError) Body ¶
func (e GenericOpenAPIError) Body() []byte
Body returns the raw bytes of the response
func (GenericOpenAPIError) Error ¶
func (e GenericOpenAPIError) Error() string
Error returns non-empty string if there was an error.
func (GenericOpenAPIError) Model ¶
func (e GenericOpenAPIError) Model() interface{}
Model returns the unpacked model of the error
type LookupBatchPostOpts ¶
LookupBatchPostOpts Optional parameters for the method 'LookupBatchPost'
type LookupPostOpts ¶
LookupPostOpts Optional parameters for the method 'LookupPost'
type LookupRequest ¶
type LookupRequest struct {
EntityName string `json:"entityName"`
}
LookupRequest struct for LookupRequest
type LookupResponse ¶
type LookupResponse struct { EntityId int64 `json:"entityId"` EntityName string `json:"entityName"` Guid string `json:"guid,omitempty"` }
LookupResponse struct for LookupResponse
type ReRegisterBatchEntityResponse ¶
type ReRegisterBatchEntityResponse struct { EntityId int64 `json:"entityId,omitempty"` EntityName string `json:"entityName,omitempty"` Guid string `json:"guid,omitempty"` Warnings []string `json:"warnings,omitempty"` Error string `json:"error,omitempty"` }
ReRegisterBatchEntityResponse struct for ReRegisterBatchEntityResponse
type ReRegisterRequest ¶
type ReRegisterRequest struct { EntityId int64 `json:"entityId"` EntityName string `json:"entityName,omitempty"` DisplayName string `json:"displayName,omitempty"` EntityType string `json:"entityType,omitempty"` Metadata map[string]string `json:"metadata,omitempty"` Source string `json:"source,omitempty"` }
ReRegisterRequest struct for ReRegisterRequest
type ReRegisterResponse ¶
type ReRegisterResponse struct { EntityId int64 `json:"entityId"` Guid string `json:"guid"` Warnings []string `json:"warnings,omitempty"` }
ReRegisterResponse struct for ReRegisterResponse
type ReconnectRequest ¶
type ReconnectRequest struct { EntityId int64 `json:"entityId"` Fingerprint Fingerprint `json:"fingerprint"` Metadata map[string]string `json:"metadata,omitempty"` Source string `json:"source,omitempty"` }
ReconnectRequest struct for ReconnectRequest
type RegisterBatchEntityResponse ¶
type RegisterBatchEntityResponse struct { EntityId int64 `json:"entityId,omitempty"` EntityName string `json:"entityName"` Guid string `json:"guid,omitempty"` Warnings []string `json:"warnings,omitempty"` Error string `json:"error,omitempty"` }
RegisterBatchEntityResponse struct for RegisterBatchEntityResponse
type RegisterBatchPostOpts ¶
type RegisterBatchPostOpts struct { ContentEncoding optional.String XNRIAgentEntityId optional.Int64 }
RegisterBatchPostOpts Optional parameters for the method 'RegisterBatchPost'
type RegisterBatchPutOpts ¶
type RegisterBatchPutOpts struct { ContentEncoding optional.String XNRIAgentEntityId optional.Int64 }
RegisterBatchPutOpts Optional parameters for the method 'RegisterBatchPut'
type RegisterPostOpts ¶
RegisterPostOpts Optional parameters for the method 'RegisterPost'
type RegisterPutOpts ¶
RegisterPutOpts Optional parameters for the method 'RegisterPut'
type RegisterRequest ¶
type RegisterRequest struct { EntityName string `json:"entityName"` DisplayName string `json:"displayName,omitempty"` EntityType string `json:"entityType,omitempty"` Metadata map[string]string `json:"metadata,omitempty"` Source string `json:"source,omitempty"` }
RegisterRequest struct for RegisterRequest
type RegisterResponse ¶
type RegisterResponse struct { EntityId int64 `json:"entityId"` EntityName string `json:"entityName"` Guid string `json:"guid"` Warnings []string `json:"warnings,omitempty"` }
RegisterResponse struct for RegisterResponse
type ServerConfiguration ¶
type ServerConfiguration struct { Url string Description string Variables map[string]ServerVariable }
ServerConfiguration stores the information about a server
type ServerVariable ¶
ServerVariable stores the information about a server variable
Source Files ¶
- api_default.go
- client.go
- configuration.go
- model_connect_request.go
- model_connect_response.go
- model_disconnect_request.go
- model_fingerprint.go
- model_identity.go
- model_lookup_request.go
- model_lookup_response.go
- model_re_register_batch_entity_response.go
- model_re_register_request.go
- model_re_register_response.go
- model_reconnect_request.go
- model_register_batch_entity_response.go
- model_register_request.go
- model_register_response.go
- response.go