connector

package
v0.1.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 27, 2026 License: Apache-2.0 Imports: 26 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const PermissionProfileResourceTypeID = "permission_profile"

PermissionProfileResourceTypeID is the resource type ID for permission profiles. Exported so other packages (e.g. connector.go) can check whether it is selected for sync via cli.ConnectorOpts.WillSyncResourceType without depending on an unexported literal drifting out of sync.

Variables

This section is empty.

Functions

func Configure added in v0.1.2

func Configure(ctx context.Context, docusignCfg *cfg.Docusign, includeClm bool) error

Configure handles the OAuth2 authorization flow to obtain a refresh token.

Types

type Connector

type Connector struct {
	// contains filtered or unexported fields
}

func NewWithRefreshToken added in v0.1.2

func NewWithRefreshToken(
	ctx context.Context, isDemo bool, clientId, clientSecret, redirectURI, refreshToken, accountId string,
	includeSigningGroups, includeClm bool, clmBaseURLOverride, baseURLOverride string,
	skipPermissionProfileResourceType, includeWorkflowQueues bool,
) (*Connector, error)

func NewWithTokenSource added in v0.1.2

func NewWithTokenSource(
	ctx context.Context, isDemo bool, tokenSource oauth2.TokenSource, accountId string,
	includeSigningGroups, includeClm bool, clmBaseURLOverride string,
	skipPermissionProfileResourceType, includeWorkflowQueues bool,
) (*Connector, error)

NewWithTokenSource's token source is minted by ConductorOne's OAuth flow, so this path can't influence which scopes were granted (unlike NewWithRefreshToken, where includeClm also drives buildScopes) — but it still needs includeClm to gate Validate()'s CLM readiness check, so it's threaded through for that purpose alone.

func (*Connector) Asset

func (*Connector) Metadata

func (d *Connector) Metadata(_ context.Context) (*v2.ConnectorMetadata, error)

func (*Connector) ResourceSyncers

func (d *Connector) ResourceSyncers(_ context.Context) []connectorbuilder.ResourceSyncerV2

func (*Connector) Validate

func (d *Connector) Validate(ctx context.Context) (annotations.Annotations, error)

Validate runs once, before any resource type's List() (see baton-sdk's pkg/sync/syncer.go Sync()), so it's the right place to check readiness a single time upfront rather than discovering a bad account mid-sync at whichever builder's List() happens to run first. EnsureReady (base eSignature credentials) runs unconditionally — every sync needs those regardless of CLM — while EnsureClmReady is gated on includeClm: an account that never opted into any CLM resource type has no reason to pay for, or fail on, a CLM discovery call it doesn't need. This gate is separate from resource-type registration (see this file's includeClm field doc) and replaces each CLM builder's own List() checking readiness independently.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL