Documentation ¶
Overview ¶
Davinci Admin API GO Client
This package is go client to be used for interacting with PingOne DaVinci Administrative APIs. Use cases include: - Creating Connections - Importing Flows
Index ¶
- func MakeFlowPayload(payload *string, output string) (*string, error)
- type APIClient
- func (c *APIClient) CreateApplication(companyId *string, appName string) (*App, error)
- func (c *APIClient) CreateConnection(companyId *string, payload *Connection) (*Connection, error)
- func (c *APIClient) CreateFlowPolicy(companyId *string, appId string, policy Policy) (*App, error)
- func (c *APIClient) CreateFlowWithJson(companyId *string, payloadJson *string) (*Flow, error)
- func (c *APIClient) CreateInitializedApplication(companyId *string, payload *AppUpdate) (*App, error)
- func (c *APIClient) CreateInitializedConnection(companyId *string, payload *Connection) (*Connection, error)
- func (c *APIClient) CreateVariable(companyId *string, variable *VariablePayload) (map[string]Variable, error)
- func (c *APIClient) DeleteApplication(companyId *string, appId string) (*Message, error)
- func (c *APIClient) DeleteConnection(companyId *string, connectionId string) (*Message, error)
- func (c *APIClient) DeleteFlow(companyId *string, flowId string) (*Message, error)
- func (c *APIClient) DeleteFlowPolicy(companyId *string, appId string, policyId string) (*Message, error)
- func (c *APIClient) DeleteVariable(companyId *string, variableName string) (*Message, error)
- func (c *APIClient) DeployFlow(companyId *string, flowId string) (*Message, error)
- func (c *APIClient) InitAuth() error
- func (c *APIClient) ParseDvHttpError(e error) (*DvHttpError, error)
- func (c *APIClient) ReadApplication(companyId *string, appId string) (*App, error)
- func (c *APIClient) ReadApplications(companyId *string, args *Params) ([]App, error)
- func (c *APIClient) ReadConnection(companyId *string, connectionId string) (*Connection, error)
- func (c *APIClient) ReadConnections(companyId *string, args *Params) ([]Connection, error)
- func (c *APIClient) ReadEnvironment(companyId *string) (*Environment, error)
- func (c *APIClient) ReadEnvironments() (*Environments, error)
- func (c *APIClient) ReadEnvironmentstats(companyId *string) (*EnvironmentStats, error)
- func (c *APIClient) ReadFlow(companyId *string, flowId string) (*FlowInfo, error)
- func (c *APIClient) ReadFlows(companyId *string, args *Params) ([]Flow, error)
- func (c *APIClient) ReadVariable(companyId *string, variableName string) (map[string]Variable, error)
- func (c *APIClient) ReadVariables(companyId *string, args *Params) (map[string]Variable, error)
- func (c *APIClient) SetEnvironment(companyId *string) (*Message, error)
- func (c *APIClient) SignIn() (*AuthResponse, error)
- func (c *APIClient) SignInSSO() (*AuthResponse, error)
- func (c *APIClient) UpdateApplication(companyId *string, payload *AppUpdate) (*App, error)
- func (c *APIClient) UpdateConnection(companyId *string, payload *Connection) (*Connection, error)
- func (c *APIClient) UpdateFlowPolicy(companyId *string, appId string, policy Policy) (*App, error)
- func (c *APIClient) UpdateFlowWithJson(companyId *string, payloadJson *string, flowId string) (*Flow, error)
- func (c *APIClient) UpdateVariable(companyId *string, variable *VariablePayload) (map[string]Variable, error)
- type APIKeys
- type App
- type AppUpdate
- type Apps
- type AuthP1SSO
- type AuthResponse
- type AuthStruct
- type AuthTypeDropdown
- type AuthorizationEndpoint
- type BearerToken
- type Callback
- type Client
- type ClientID
- type ClientInput
- type ClientSecret
- type Code
- type Companies
- type Connection
- type CreatedCustomer
- type CustomAttributes
- type CustomAttributesValue
- type CustomAuth
- type CustomAuthProperties
- type Customer
- type CustomerCreate
- type CustomerUpdate
- type Customers
- type Data
- type DvHttpError
- type DvHttpRequest
- type DvHttpResponse
- type EdgeData
- type Edges
- type Elements
- type Email
- type Environment
- type EnvironmentStats
- type Environments
- type FirstName
- type Flow
- type FlowImport
- type FlowInfo
- type FlowUpdate
- type Flows
- type FlowsImport
- type FlowsInfo
- type GraphData
- type IssuerURL
- type LastName
- type LoginResponse
- type Mapping
- type Message
- type Metadata
- type Name
- type NodeData
- type Nodes
- type Oauth
- type OauthValues
- type Options
- type OutputSchema
- type Pan
- type Params
- type Placeholder
- type Policy
- type PolicyFlow
- type Position
- type Properties
- type ProviderName
- type ReadApp
- type Renderer
- type ReturnToURL
- type Role
- type RoleCreate
- type RoleCreateResponse
- type RoleUpdate
- type Saml
- type SamlValues
- type Scope
- type SkRedirectURI
- type SkSdkToken
- type SubFlowID
- type SubFlowProperties
- type SubFlowValue
- type SubFlowVersionID
- type TokenEndpoint
- type Trigger
- type UserConnectorAttributeMapping
- type UserConnectorAttributeMappingPlaceholder
- type UserConnectorAttributeMappingValue
- type UserInfoEndpoint
- type UserPools
- type UserPortal
- type UserPortalValues
- type Username
- type Values
- type Variable
- type VariablePayload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type APIClient ¶
type APIClient struct { HostURL string PingOneRegion string HTTPClient *http.Client Token string Auth AuthStruct CompanyID string PingOneSSOEnvId string AuthRefresh bool }
func NewClient ¶
func NewClient(inputs *ClientInput) (*APIClient, error)
func (*APIClient) CreateApplication ¶
func (*APIClient) CreateConnection ¶
func (c *APIClient) CreateConnection(companyId *string, payload *Connection) (*Connection, error)
Create a bare connection, properties can be added _after_ creation
func (*APIClient) CreateFlowPolicy ¶ added in v0.0.30
func (*APIClient) CreateFlowWithJson ¶
func (*APIClient) CreateInitializedApplication ¶
func (c *APIClient) CreateInitializedApplication(companyId *string, payload *AppUpdate) (*App, error)
CreateInitializedApplication is useful when creating an application with flow policy. Takes an app payload and calls: - CreateApplication - UpdateApplication - CreateFlowPolicy
func (*APIClient) CreateInitializedConnection ¶
func (c *APIClient) CreateInitializedConnection(companyId *string, payload *Connection) (*Connection, error)
Create a connection and fill connection properties
Sample minimal payload:
&Connection{ ConnectorID: "fooConnector" Name: "Foo Connector" Properties: Properties{ "foo": struct { Value string `json:"value"` }{"bar"} } }
func (*APIClient) CreateVariable ¶ added in v0.0.27
func (*APIClient) DeleteApplication ¶
Deletes an application based on applicationId
func (*APIClient) DeleteConnection ¶
Deletes a connection based on ConnectionId
func (*APIClient) DeleteFlow ¶
ReadFlows only accepts Limit as a param
func (*APIClient) DeleteFlowPolicy ¶ added in v0.0.30
func (c *APIClient) DeleteFlowPolicy(companyId *string, appId string, policyId string) (*Message, error)
Deletes an application based on applicationId
func (*APIClient) DeleteVariable ¶ added in v0.0.27
func (*APIClient) DeployFlow ¶
ReadFlows only accepts Limit as a param
func (*APIClient) ParseDvHttpError ¶
func (c *APIClient) ParseDvHttpError(e error) (*DvHttpError, error)
sample incoming must be formatted as similar to: fmt.Errorf("status: %d, body: %s", res.StatusCode, body)
func (*APIClient) ReadApplication ¶
func (*APIClient) ReadApplications ¶
ReadFlows only accepts Limit as a param
func (*APIClient) ReadConnection ¶
func (c *APIClient) ReadConnection(companyId *string, connectionId string) (*Connection, error)
Gets single connections based on ConnectionId
func (*APIClient) ReadConnections ¶
func (c *APIClient) ReadConnections(companyId *string, args *Params) ([]Connection, error)
Gets array of all connections for the provided company
func (*APIClient) ReadEnvironment ¶
func (c *APIClient) ReadEnvironment(companyId *string) (*Environment, error)
func (*APIClient) ReadEnvironments ¶
func (c *APIClient) ReadEnvironments() (*Environments, error)
Returns list of Environments (auth required)
func (*APIClient) ReadEnvironmentstats ¶
func (c *APIClient) ReadEnvironmentstats(companyId *string) (*EnvironmentStats, error)
func (*APIClient) ReadVariable ¶ added in v0.0.27
func (*APIClient) ReadVariables ¶ added in v0.0.27
func (*APIClient) SetEnvironment ¶
func (*APIClient) SignIn ¶
func (c *APIClient) SignIn() (*AuthResponse, error)
SignIn - Get a new token for user
func (*APIClient) SignInSSO ¶
func (c *APIClient) SignInSSO() (*AuthResponse, error)
func (*APIClient) UpdateApplication ¶
UpdateApplication - Update all fields of an application besides Policies. Policies should be updated via UpdatePolicy
func (*APIClient) UpdateConnection ¶
func (c *APIClient) UpdateConnection(companyId *string, payload *Connection) (*Connection, error)
Update existing connection properties.
Sample minimal payload:
&Connection{ ConnectionID: "foo-123" Properties: Properties{ "foo": struct { Value string `json:"value"` }{"bar"} } }
func (*APIClient) UpdateFlowPolicy ¶ added in v0.0.30
func (*APIClient) UpdateFlowWithJson ¶
func (c *APIClient) UpdateFlowWithJson(companyId *string, payloadJson *string, flowId string) (*Flow, error)
Only specific fields are supported during update: - GraphData - InputSchema - CurrentVersion - Name
func (*APIClient) UpdateVariable ¶ added in v0.0.27
func (c *APIClient) UpdateVariable(companyId *string, variable *VariablePayload) (map[string]Variable, error)
UpdateVariable can update fields besides Name and Context
type App ¶
type App struct { CompanyID string `json:"companyId,omitempty"` Name string `json:"name"` CustomerID string `json:"customerId,omitempty"` APIKeys *APIKeys `json:"apiKeys,omitempty"` Metadata *Metadata `json:"metadata,omitempty"` UserPools []UserPools `json:"userPools,omitempty"` Oauth *Oauth `json:"oauth,omitempty"` Saml *Saml `json:"saml,omitempty"` Flows []interface{} `json:"flows,omitempty"` Policies []Policy `json:"policies,omitempty"` CreatedDate int64 `json:"createdDate,omitempty"` APIKeyEnabled bool `json:"apiKeyEnabled,omitempty"` AppID string `json:"appId,omitempty"` UserPortal *UserPortal `json:"userPortal,omitempty"` }
type AppUpdate ¶
type AppUpdate struct { Name string `json:"name"` Oauth *Oauth `json:"oauth,omitempty"` Saml *Saml `json:"saml,omitempty"` Flows []interface{} `json:"flows,omitempty"` Policies []Policy `json:"policies,omitempty"` APIKeyEnabled bool `json:"apiKeyEnabled,omitempty"` AppID string `json:"appId,omitempty"` UserPortal *UserPortal `json:"userPortal,omitempty"` }
type AuthResponse ¶
type AuthStruct ¶
type AuthTypeDropdown ¶ added in v0.0.37
type AuthTypeDropdown struct { DisplayName string `json:"displayName,omitempty"` PreferredControlType string `json:"preferredControlType,omitempty"` Required bool `json:"required,omitempty"` Options []Options `json:"options,omitempty"` Enum []string `json:"enum,omitempty"` Value string `json:"value,omitempty"` Placeholder string `json:"placeholder,omitempty"` }
type AuthorizationEndpoint ¶ added in v0.0.37
type BearerToken ¶ added in v0.0.37
type BearerToken struct { PreferredControlType string `json:"preferredControlType,omitempty"` Type string `json:"type,omitempty"` DisplayName string `json:"displayName,omitempty"` Info string `json:"info,omitempty"` Value string `json:"value,omitempty"` Placeholder string `json:"placeholder,omitempty"` }
type Callback ¶
type Callback struct { InteractionID string `json:"interactionId"` CompanyID string `json:"companyId"` ConnectionID string `json:"connectionId"` ConnectorID string `json:"connectorId"` ID string `json:"id"` CapabilityName string `json:"capabilityName"` AccessToken string `json:"access_token"` TokenType string `json:"token_type"` ExpiresIn int `json:"expires_in"` IDToken string `json:"id_token"` Success bool `json:"success"` InteractionToken string `json:"interactionToken"` }
type ClientInput ¶
type ClientSecret ¶ added in v0.0.37
type ClientSecret struct { DisplayName string `json:"displayName,omitempty"` PreferredControlType string `json:"preferredControlType,omitempty"` HashedVisibility bool `json:"hashedVisibility,omitempty"` Required bool `json:"required,omitempty"` Value string `json:"value,omitempty"` Placeholder string `json:"placeholder,omitempty"` }
type Code ¶ added in v0.0.37
type Code struct { DisplayName string `json:"displayName,omitempty"` Info string `json:"info,omitempty"` PreferredControlType string `json:"preferredControlType,omitempty"` Language string `json:"language,omitempty"` Value string `json:"value,omitempty"` Placeholder string `json:"placeholder,omitempty"` }
type Connection ¶
type Connection struct { CustomerID string `json:"customerId,omitempty"` ConnectorID string `json:"connectorId,omitempty"` Name string `json:"name,omitempty"` CreatedDate int64 `json:"createdDate,omitempty"` Properties Properties `json:"properties,omitempty"` UpdatedDate int64 `json:"updatedDate,omitempty"` ConnectionID string `json:"connectionId,omitempty"` CompanyID string `json:"companyId,omitempty"` }
Representation of an instantiated connector All fields are set with omitempty as nil values aren't allowed to various requests requiring specific fields.
type CreatedCustomer ¶
type CreatedCustomer struct { Email string `json:"email"` CompanyID string `json:"companyId"` ClientID interface{} `json:"clientId"` FirstName string `json:"firstName"` LastName string `json:"lastName"` PhoneNumber interface{} `json:"phoneNumber"` CreatedByCustomerID string `json:"createdByCustomerId"` CreatedByCompanyID string `json:"createdByCompanyId"` EmailVerified bool `json:"emailVerified"` Companies []Companies `json:"companies"` Salt string `json:"salt"` HashedPassword string `json:"hashedPassword"` Status string `json:"status"` CustomerType string `json:"customerType"` CreatedDate int64 `json:"createdDate"` EmailVerifiedDate int64 `json:"emailVerifiedDate"` PasswordHistory []struct { HashedPassword string `json:"hashedPassword"` Salt string `json:"salt"` AddedDate int64 `json:"addedDate"` } `json:"passwordHistory"` SkUserID string `json:"skUserId"` LastLogin int64 `json:"lastLogin"` FailedLogin struct { RetryCount int `json:"retryCount"` FirstFailedTimestamp int64 `json:"firstFailedTimestamp"` } `json:"failedLogin"` CustomerID string `json:"customerId"` }
type CustomAttributes ¶ added in v0.0.37
type CustomAttributes struct { Type string `json:"type,omitempty"` DisplayName string `json:"displayName,omitempty"` PreferredControlType string `json:"preferredControlType,omitempty"` Info string `json:"info,omitempty"` Sections []string `json:"sections,omitempty"` Value []CustomAttributesValue `json:"value,omitempty"` Placeholder []Placeholder `json:"placeholder,omitempty"` }
type CustomAttributesValue ¶ added in v0.0.37
type CustomAttributesValue struct { Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Type string `json:"type,omitempty"` Value interface{} `json:"value,omitempty"` MinLength string `json:"minLength,omitempty"` MaxLength string `json:"maxLength,omitempty"` Required bool `json:"required,omitempty"` AttributeType string `json:"attributeType,omitempty"` }
type CustomAuth ¶ added in v0.0.37
type CustomAuth struct {
Properties CustomAuthProperties `json:"properties,omitempty"`
}
CustomAuth is a field of the Properties struct but is kept separate because the structure is known. This is used to unmarshal the properties["customAuth"] field of a connection response.
type CustomAuthProperties ¶ added in v0.0.37
type CustomAuthProperties struct { ProviderName ProviderName `json:"providerName,omitempty"` AuthTypeDropdown AuthTypeDropdown `json:"authTypeDropdown,omitempty"` SkRedirectURI SkRedirectURI `json:"skRedirectUri,omitempty"` IssuerURL IssuerURL `json:"issuerUrl,omitempty"` AuthorizationEndpoint AuthorizationEndpoint `json:"authorizationEndpoint,omitempty"` TokenEndpoint TokenEndpoint `json:"tokenEndpoint,omitempty"` BearerToken BearerToken `json:"bearerToken,omitempty"` UserInfoEndpoint UserInfoEndpoint `json:"userInfoEndpoint,omitempty"` ClientID ClientID `json:"clientId,omitempty"` ClientSecret ClientSecret `json:"clientSecret,omitempty"` Scope Scope `json:"scope,omitempty"` Code Code `json:"code,omitempty"` UserConnectorAttributeMapping UserConnectorAttributeMapping `json:"userConnectorAttributeMapping,omitempty"` CustomAttributes CustomAttributes `json:"customAttributes,omitempty"` ReturnToURL ReturnToURL `json:"returnToUrl,omitempty"` }
type Customer ¶
type Customer struct { Email string `json:"email"` FirstName string `json:"firstName"` LastName string `json:"lastName"` Companies []struct { CompanyID string `json:"companyId"` Roles []string `json:"roles"` } `json:"companies"` CustomerType string `json:"customerType"` CreatedByCustomerID string `json:"createdByCustomerId"` CreatedByCompanyID string `json:"createdByCompanyId"` CompanyID string `json:"companyId"` EmailVerified bool `json:"emailVerified"` CreatedDate int64 `json:"createdDate"` LastLogin int64 `json:"lastLogin"` SkUserID string `json:"skUserId,omitempty"` CustomerID string `json:"customerId"` ClientID string `json:"clientId,omitempty"` PhoneNumber string `json:"phoneNumber,omitempty"` Status string `json:"status,omitempty"` EmailVerifiedDate int64 `json:"emailVerifiedDate,omitempty"` }
type CustomerCreate ¶
type CustomerUpdate ¶
type Data ¶ added in v0.0.32
type Data struct { ID string `json:"id,omitempty"` NodeType string `json:"nodeType,omitempty"` ConnectionID string `json:"connectionId,omitempty"` ConnectorID string `json:"connectorId,omitempty"` Name string `json:"name,omitempty"` Label string `json:"label,omitempty"` Status string `json:"status,omitempty"` CapabilityName string `json:"capabilityName,omitempty"` Type string `json:"type,omitempty"` // have not removed omitempty on general Data struct, not sure if it is needed Properties Properties `json:"properties,omitempty"` Source string `json:"source,omitempty"` Target string `json:"target,omitempty"` MultiValueSourceId string `json:"multiValueSourceId,omitempty"` }
type DvHttpError ¶
func ParseDvHttpError ¶ added in v0.0.35
func ParseDvHttpError(e error) (*DvHttpError, error)
sample incoming must be formatted as similar to: fmt.Errorf("status: %d, body: %s", res.StatusCode, body)
type DvHttpResponse ¶
type EdgeData ¶ added in v0.0.37
type EdgeData struct { ID string `json:"id,omitempty"` NodeType string `json:"nodeType,omitempty"` ConnectionID string `json:"connectionId,omitempty"` ConnectorID string `json:"connectorId,omitempty"` Name string `json:"name,omitempty"` Label string `json:"label,omitempty"` Status string `json:"status,omitempty"` CapabilityName string `json:"capabilityName,omitempty"` Type string `json:"type,omitempty"` Properties Properties `json:"properties,omitempty"` Source string `json:"source,omitempty"` Target string `json:"target,omitempty"` MultiValueSourceId string `json:"multiValueSourceId,omitempty"` }
type Edges ¶ added in v0.0.32
type Edges struct { Data EdgeData `json:"data,omitempty"` Position Position `json:"position,omitempty"` Group string `json:"group"` Removed bool `json:"removed"` Selected bool `json:"selected"` Selectable bool `json:"selectable"` Locked bool `json:"locked"` Grabbable bool `json:"grabbable"` Pannable bool `json:"pannable"` Classes string `json:"classes"` }
type Environment ¶
type Environment struct { CreatedByCustomerID string `json:"createdByCustomerId"` CreatedByCompanyID string `json:"createdByCompanyId"` Name string `json:"name"` CompanyType string `json:"companyType"` EntitlementTemplate string `json:"entitlementTemplate"` EntitlementProps struct { } `json:"entitlementProps"` SecurityType string `json:"securityType"` JwtKeys struct { Jwks struct { Keys []struct { Kty string `json:"kty"` Kid string `json:"kid"` N string `json:"n"` E string `json:"e"` Alg string `json:"alg"` Use string `json:"use"` } `json:"keys"` } `json:"jwks"` } `json:"jwtKeys"` SamlKeys struct { PublicKey string `json:"publicKey"` Cert string `json:"cert"` } `json:"samlKeys"` Properties struct { PngIcon struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"pngIcon"` SvgIcon struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"svgIcon"` SvgViewBox struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"svgViewBox"` IconOpacity struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value float64 `json:"value"` } `json:"iconOpacity"` BackgroundColor struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"backgroundColor"` TextColor struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"textColor"` IconColor struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"iconColor"` ArcColor struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"arcColor"` ArcProgressColor struct { DisplayName string `json:"displayName"` DataType string `json:"dataType"` PreferredControlType string `json:"preferredControlType"` Value string `json:"value"` } `json:"arcProgressColor"` } `json:"properties"` CreatedDate int64 `json:"createdDate"` Entitlement struct { Company struct { CreateAdditional bool `json:"createAdditional"` } `json:"company"` Connectors struct { Whitelist []string `json:"whitelist"` //TODO // Blacklist []string `json:"blacklist"` Blacklist interface{} `json:"blacklist"` } `json:"connectors"` Connections struct { Total int `json:"total"` MaxNumberOfConnectionsPerConnector struct { ConnectorID string `json:"connectorId"` Total int `json:"total"` } `json:"maxNumberOfConnectionsPerConnector"` } `json:"connections"` Flows struct { Enabled bool `json:"enabled"` Total int `json:"total"` Expires int64 `json:"expires"` } `json:"flows"` Attributes struct { Enabled bool `json:"enabled"` Total int `json:"total"` } `json:"attributes"` Apps struct { Total int `json:"total"` } `json:"apps"` Users struct { Total int `json:"total"` TotalCredentialsPerUser int `json:"totalCredentialsPerUser"` } `json:"users"` Expires int64 `json:"expires"` } `json:"entitlement"` CompanyID string `json:"companyId"` }
type EnvironmentStats ¶
type EnvironmentStats struct { TableStats []struct { Flows int `json:"Flows"` Connections int `json:"Connections"` Apps int `json:"Apps"` Customers int `json:"Customers"` Constructs int `json:"Constructs"` Users int `json:"Users"` Events int `json:"Events"` ID struct { CompanyID string `json:"companyId"` Ts int64 `json:"ts"` } `json:"_id"` } `json:"tableStats"` PopularFlows []struct { Key string `json:"key"` DocCount int `json:"doc_count"` Name string `json:"name,omitempty"` } `json:"popularFlows"` RunningFlowsCount []struct { KeyAsString time.Time `json:"key_as_string"` Key int64 `json:"key"` DocCount int `json:"doc_count"` } `json:"runningFlowsCount"` EventOutcomesCount []interface{} `json:"eventOutcomesCount"` AllFlows []string `json:"allFlows"` }
type Environments ¶
type Environments struct { CustomerID string `json:"customerId"` FirstName string `json:"firstName"` LastName string `json:"lastName"` Email string `json:"email"` PhoneNumber string `json:"phoneNumber"` CompanyID string `json:"companyId"` Companies []Companies `json:"companies"` ClientID string `json:"clientId,omitempty"` CreatedDate int64 `json:"createdDate"` }
type Flow ¶
type Flow struct { CustomerID string `json:"customerId,omitempty"` FlowStatus string `json:"flowStatus,omitempty"` CurrentVersion int `json:"currentVersion,omitempty"` PublishedVersion int `json:"publishedVersion,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` CreatedDate int64 `json:"createdDate,omitempty"` UpdatedDate int64 `json:"updatedDate,omitempty"` AuthTokenExpireIds []interface{} `json:"authTokenExpireIds,omitempty"` DeployedDate int64 `json:"deployedDate,omitempty"` // Edited, removed struct. Staying one level only EnabledGraphData interface{} `json:"enabledGraphData,omitempty"` FunctionConnectionID interface{} `json:"functionConnectionId,omitempty"` // edited InputSchemaCompiled interface{} `json:"inputSchemaCompiled,omitempty"` IsInputSchemaSaved bool `json:"isInputSchemaSaved,omitempty"` IsOutputSchemaSaved bool `json:"isOutputSchemaSaved,omitempty"` Orx string `json:"orx,omitempty"` Settings interface{} `json:"settings,omitempty"` Trigger Trigger `json:"trigger"` Timeouts interface{} `json:"timeouts,omitempty"` FlowID string `json:"flowId,omitempty"` CompanyID string `json:"companyId,omitempty"` GraphData GraphData `json:"graphData,omitempty"` InputSchema []interface{} `json:"inputSchema"` OutputSchema OutputSchema `json:"outputSchema"` //compiled is used in exported flow json, must be converted to JUST output when updating flow. OutputSchemaCompiled OutputSchema `json:"outputSchemaCompiled"` FlowColor string `json:"flowColor,omitempty"` ConnectorIds []string `json:"connectorIds,omitempty"` SavedDate int64 `json:"savedDate,omitempty"` }
func ParseFlowJson ¶ added in v0.0.32
type FlowImport ¶
type FlowImport struct { Name string `json:"name,omitempty"` Description string `json:"description"` FlowInfo Flow `json:"flowInfo,omitempty"` FlowNameMapping map[string]string `json:"flowNameMapping,omitempty"` }
func ParseFlowImportJson ¶ added in v0.0.32
func ParseFlowImportJson(payload *string) (*FlowImport, error)
type FlowUpdate ¶ added in v0.0.44
type FlowUpdate struct { CurrentVersion int `json:"currentVersion,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Settings interface{} `json:"settings,omitempty"` Trigger Trigger `json:"trigger"` GraphData GraphData `json:"graphData,omitempty"` InputSchema []interface{} `json:"inputSchema"` OutputSchema OutputSchema `json:"outputSchema"` }
Used specifically for PUTs to existing flows.
type FlowsImport ¶ added in v0.0.31
type FlowsImport struct { Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` FlowInfo Flows `json:"flowInfo,omitempty"` FlowNameMapping map[string]string `json:"flowNameMapping,omitempty"` }
func ParseFlowsImportJson ¶ added in v0.0.32
func ParseFlowsImportJson(payload *string) (*FlowsImport, error)
type GraphData ¶
type GraphData struct { Elements Elements `json:"elements,omitempty"` Data Data `json:"data,omitempty"` ZoomingEnabled bool `json:"zoomingEnabled,omitempty"` UserZoomingEnabled bool `json:"userZoomingEnabled,omitempty"` Zoom int `json:"zoom,omitempty"` MinZoom float64 `json:"minZoom,omitempty"` MaxZoom float64 `json:"maxZoom,omitempty"` PanningEnabled bool `json:"panningEnabled,omitempty"` UserPanningEnabled bool `json:"userPanningEnabled,omitempty"` Pan Pan `json:"pan,omitempty"` BoxSelectionEnabled bool `json:"boxSelectionEnabled,omitempty"` Renderer Renderer `json:"renderer,omitempty"` }
type LoginResponse ¶
type LoginResponse struct { AccessToken string `json:"access_token"` TokenType string `json:"token_type"` MfaRequired bool `json:"mfaRequired"` Status string `json:"status"` CustomerID string `json:"customerId"` AppConfig bool `json:"appConfig"` SkSdkToken SkSdkToken `json:"skSdkToken"` FlowPolicyID string `json:"flowPolicyId"` CompanyID string `json:"companyId"` SelectedCompany string `json:"selectedCompany"` }
type NodeData ¶ added in v0.0.37
type NodeData struct { ID string `json:"id,omitempty"` NodeType string `json:"nodeType,omitempty"` ConnectionID string `json:"connectionId,omitempty"` ConnectorID string `json:"connectorId,omitempty"` Name string `json:"name,omitempty"` Label string `json:"label,omitempty"` Status string `json:"status,omitempty"` CapabilityName string `json:"capabilityName,omitempty"` Type string `json:"type,omitempty"` Properties Properties `json:"properties"` Source string `json:"source,omitempty"` Target string `json:"target,omitempty"` }
type Nodes ¶ added in v0.0.32
type Nodes struct { Data NodeData `json:"data,omitempty"` Position Position `json:"position,omitempty"` Group string `json:"group"` Removed bool `json:"removed"` Selected bool `json:"selected"` Selectable bool `json:"selectable"` Locked bool `json:"locked"` Grabbable bool `json:"grabbable"` Pannable bool `json:"pannable"` Classes string `json:"classes"` }
type Oauth ¶
type Oauth struct { Enabled bool `json:"enabled,omitempty"` Values *OauthValues `json:"values,omitempty"` }
type OauthValues ¶
type OauthValues struct { Enabled bool `json:"enabled,omitempty"` ClientSecret string `json:"clientSecret,omitempty"` RedirectUris []string `json:"redirectUris,omitempty"` LogoutUris []string `json:"logoutUris,omitempty"` AllowedScopes []string `json:"allowedScopes,omitempty"` AllowedGrants []string `json:"allowedGrants,omitempty"` EnforceSignedRequestOpenid bool `json:"enforceSignedRequestOpenid,omitempty"` SpjwksUrl string `json:"spjwksUrl,omitempty"` SpJwksOpenid string `json:"spJwksOpenid,omitempty"` }
type OutputSchema ¶ added in v0.0.44
type OutputSchema struct {
Output interface{} `json:"output,omitempty"`
}
type Params ¶
func (Params) QueryParams ¶
type Placeholder ¶ added in v0.0.37
type Placeholder struct { Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Type string `json:"type,omitempty"` Value interface{} `json:"value,omitempty"` MinLength string `json:"minLength,omitempty"` MaxLength string `json:"maxLength,omitempty"` Required bool `json:"required,omitempty"` AttributeType string `json:"attributeType,omitempty"` }
type PolicyFlow ¶ added in v0.0.30
type Properties ¶
type Properties map[string]interface{}
type ProviderName ¶ added in v0.0.37
type ReturnToURL ¶ added in v0.0.37
type Role ¶
type Role struct { ID struct { Name string `json:"name,omitempty"` CompanyID string `json:"companyId,omitempty"` } `json:"_id,omitempty"` CreatedDate int64 `json:"createdDate,omitempty"` Description string `json:"description,omitempty"` Policy []struct { Resource string `json:"resource,omitempty"` Actions []struct { Action string `json:"action,omitempty"` Allow bool `json:"allow,omitempty"` } `json:"actions,omitempty"` } `json:"policy,omitempty"` }
TODO: Cleanup roles
type RoleCreate ¶
type RoleCreate struct {
Name string `json:"name"`
}
type RoleCreateResponse ¶
type RoleUpdate ¶
type Saml ¶
type Saml struct {
Values *SamlValues `json:"values,omitempty"`
}
type SamlValues ¶
type SkRedirectURI ¶ added in v0.0.37
type SkSdkToken ¶
type SubFlowID ¶ added in v0.0.32
type SubFlowID struct {
Value SubFlowValue `json:"value,omitempty" mapstructure:"value"`
}
type SubFlowProperties ¶ added in v0.0.32
type SubFlowProperties struct { SubFlowID SubFlowID `json:"subFlowId,omitempty" mapstructure:"subFlowId"` SubFlowVersionID SubFlowVersionID `json:"subFlowVersionId,omitempty" mapstructure:"subFlowVersionId"` }
Used for type assertion on Properties of a Node Data
type SubFlowValue ¶ added in v0.0.32
type SubFlowValue struct { Label string `json:"label,omitempty" mapstructure:"label"` Value string `json:"value,omitempty" mapstructure:"value"` }
type ShowContinueButton struct { Value bool `json:"value,omitempty"` }
type SubFlowVersionID ¶ added in v0.0.32
type SubFlowVersionID struct {
Value string `json:"value,omitempty" mapstructure:"value"`
}
type TokenEndpoint ¶ added in v0.0.37
type UserConnectorAttributeMapping ¶ added in v0.0.37
type UserConnectorAttributeMapping struct { Type string `json:"type,omitempty"` DisplayName interface{} `json:"displayName,omitempty"` PreferredControlType string `json:"preferredControlType,omitempty"` NewMappingAllowed bool `json:"newMappingAllowed,omitempty"` Title1 interface{} `json:"title1,omitempty"` Title2 interface{} `json:"title2,omitempty"` Sections []string `json:"sections,omitempty"` Value UserConnectorAttributeMappingValue `json:"value,omitempty"` Placeholder UserConnectorAttributeMappingPlaceholder `json:"placeholder,omitempty"` }
type UserConnectorAttributeMappingPlaceholder ¶ added in v0.0.37
type UserConnectorAttributeMappingValue ¶ added in v0.0.37
type UserInfoEndpoint ¶ added in v0.0.37
type UserPortal ¶
type UserPortal struct {
Values *UserPortalValues `json:"values"`
}
type UserPortalValues ¶
type UserPortalValues struct { UpTitle string `json:"upTitle"` AddAuthMethodTitle string `json:"addAuthMethodTitle"` FlowTimeoutInSeconds int `json:"flowTimeoutInSeconds"` CredentialPageTitle string `json:"credentialPageTitle"` CredentialPageSubTitle string `json:"credentialPageSubTitle"` ShowUserInfo bool `json:"showUserInfo"` ShowMfaButton bool `json:"showMfaButton"` ShowVariables bool `json:"showVariables"` ShowLogoutButton bool `json:"showLogoutButton"` NameAuthMethodTitle string `json:"nameAuthMethodTitle"` NameConfirmButtonText string `json:"nameConfirmButtonText"` UpdateMessage string `json:"updateMessage"` UpdateBodyMessage string `json:"updateBodyMessage"` RemoveAuthMethodTitle string `json:"removeAuthMethodTitle"` RemoveMessage string `json:"removeMessage"` RemoveBodyMessage string `json:"removeBodyMessage"` RemoveConfirmButtonText string `json:"removeConfirmButtonText"` RemoveCancelButtonText string `json:"removeCancelButtonText"` }
type Values ¶
type Values struct { Enabled bool `json:"enabled,omitempty"` ClientSecret string `json:"clientSecret,omitempty"` RedirectUris []string `json:"redirectUris,omitempty"` LogoutUris []interface{} `json:"logoutUris,omitempty"` AllowedScopes []string `json:"allowedScopes,omitempty"` AllowedGrants []string `json:"allowedGrants,omitempty"` }
type Variable ¶ added in v0.0.27
type Variable struct { Context string `json:"context,omitempty"` CreatedDate int64 `json:"createdDate,omitempty"` CustomerID string `json:"customerId,omitempty"` Type string `json:"type,omitempty"` Visibility string `json:"visibility,omitempty"` CompanyID string `json:"companyId,omitempty"` TotalCount int `json:"totalCount,omitempty"` DisplayName string `json:"displayName,omitempty"` Value string `json:"value,omitempty"` Mutable bool `json:"mutable,omitempty"` Min int `json:"min,omitempty"` Max int `json:"max,omitempty"` }
type VariablePayload ¶ added in v0.0.27
type VariablePayload struct { Name string `json:"name,omitempty"` Description string `json:"displayName,omitempty"` Context string `json:"context,omitempty" validate:"oneof=company flowInstance user"` Type string `json:"type,omitempty"` Value string `json:"value,omitempty"` Mutable bool `json:"mutable,omitempty"` Min int `json:"min,omitempty"` Max int `json:"max,omitempty"` }