config

package
v0.1.7-test Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2026 License: Apache-2.0 Imports: 2 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

Overview

Code generated by baton-sdk. DO NOT EDIT!!!

Index

Constants

This section is empty.

Variables

View Source
var (
	// IsDemoField is CLI-only: demo mode is implied in the GUI by selecting the "demo" field group.
	IsDemoField = field.BoolField(
		"demo",
		field.WithDisplayName("Demo Environment"),
		field.WithDescription("Set to true for demo environment, false for production"),
		field.WithDefaultValue(false),
		field.WithExportTarget(field.ExportTargetCLIOnly),
	)

	ClientIdField = field.StringField(
		"docusign-client-id",
		field.WithDisplayName("Client ID"),
		field.WithDescription("OAuth 2.0 Client ID from your DocuSign developer app"),
		field.WithRequired(true),
	)

	ClientSecretField = field.StringField(
		"docusign-client-secret",
		field.WithDisplayName("Client Secret"),
		field.WithDescription("OAuth 2.0 Client Secret from your DocuSign developer app"),
		field.WithIsSecret(true),
		field.WithRequired(true),
	)

	RedirectURIField = field.StringField(
		"redirect-uri",
		field.WithDisplayName("Redirect URI"),
		field.WithDescription("Redirect URI registered in your DocuSign integration"),
		field.WithExportTarget(field.ExportTargetCLIOnly),
	)

	RefreshTokenField = field.StringField(
		"refresh-token",
		field.WithDisplayName("Refresh Token"),
		field.WithDescription("OAuth 2.0 Refresh Token for DocuSign"),
		field.WithIsSecret(true),
		field.WithExportTarget(field.ExportTargetCLIOnly),
	)

	ConfigureField = field.BoolField(
		"configure",
		field.WithDisplayName("Configure"),
		field.WithDescription("Get the refresh token the first time you run the connector."),
		field.WithExportTarget(field.ExportTargetCLIOnly),
	)

	AccountIdField = field.StringField(
		"account-id",
		field.WithDisplayName("DocuSign Account ID"),
		field.WithDescription("API account ID (UUID format) of the DocuSign account to be used for synchronization. "+
			"Leave blank to use your default account. "+
			"Warning: changing this ID between different synchronizations may result in data loss. "+
			"If you want to synchronize different accounts, create different connectors."),
	)

	IncludeSigningGroupsField = field.BoolField(
		"include-signing-groups",
		field.WithDisplayName("Include Signing Groups"),
		field.WithDescription("Set to true to include syncing signing groups (for customers with signing groups feature enabled)"),
		field.WithDefaultValue(false),
	)

	Oauth2TokenField = field.Oauth2Field(
		"oauth2-token",
		field.WithDisplayName("OAuth Authentication"),
		field.WithDescription("OAuth 2.0 Authentication for DocuSign"),
	)

	// ConfigurationFields defines the external configuration required for the
	// connector to run. Note: these fields can be marked as optional or
	// required.
	ConfigurationFields = []field.SchemaField{
		IsDemoField,
		ClientIdField,
		ClientSecretField,
		RedirectURIField,
		RefreshTokenField,
		ConfigureField,
		AccountIdField,
		IncludeSigningGroupsField,
		Oauth2TokenField,
	}

	// FieldRelationships defines relationships between the ConfigurationFields that can be automatically validated.
	// For example, a username and password can be required together, or an access token can be
	// marked as mutually exclusive from the username password pair.
	FieldRelationships = []field.SchemaFieldRelationship{
		field.FieldsMutuallyExclusive(RefreshTokenField, Oauth2TokenField),
	}

	// FieldGroups defines how fields are presented in the C1 UI.
	// The "oauth2" group (default) uses ConductorOne's managed DocuSign OAuth app for production.
	// The "demo" group lets customers supply their own DocuSign developer app credentials
	// against DocuSign's demo environment.
	FieldGroups = []field.SchemaFieldGroup{
		{
			Name:        "oauth2",
			DisplayName: "OAuth Authentication",
			HelpText:    "Authenticate using ConductorOne's managed DocuSign OAuth app (production environment).",
			Default:     true,
			Fields:      []field.SchemaField{Oauth2TokenField, AccountIdField, IncludeSigningGroupsField},
		},
		{
			Name:        "demo",
			DisplayName: "Custom App (Demo Environment)",
			HelpText: "Authenticate using your own DocuSign developer app against DocuSign's demo environment. " +
				"Provide your app's Client ID and Client Secret, then click the OAuth button to authorize.",
			Fields: []field.SchemaField{ClientIdField, ClientSecretField, Oauth2TokenField, AccountIdField, IncludeSigningGroupsField},
		},
	}
)
View Source
var ConfigurationSchema = field.NewConfiguration(
	ConfigurationFields,
	field.WithConstraints(FieldRelationships...),
	field.WithConnectorDisplayName("DocuSign"),
	field.WithHelpUrl("/docs/baton/docusign"),
	field.WithIconUrl("/static/app-icons/docusign.svg"),
	field.WithFieldGroups(FieldGroups),
)

Functions

This section is empty.

Types

type Docusign

type Docusign struct {
	Demo                 bool   `mapstructure:"demo"`
	DocusignClientId     string `mapstructure:"docusign-client-id"`
	DocusignClientSecret string `mapstructure:"docusign-client-secret"`
	RedirectUri          string `mapstructure:"redirect-uri"`
	RefreshToken         string `mapstructure:"refresh-token"`
	Configure            bool   `mapstructure:"configure"`
	AccountId            string `mapstructure:"account-id"`
	IncludeSigningGroups bool   `mapstructure:"include-signing-groups"`
	Oauth2Token          string `mapstructure:"oauth2-token"`
}

func (*Docusign) GetBool

func (c *Docusign) GetBool(fieldName string) bool

func (*Docusign) GetInt

func (c *Docusign) GetInt(fieldName string) int

func (*Docusign) GetString

func (c *Docusign) GetString(fieldName string) string

func (*Docusign) GetStringMap

func (c *Docusign) GetStringMap(fieldName string) map[string]any

func (*Docusign) GetStringSlice

func (c *Docusign) GetStringSlice(fieldName string) []string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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