Table of Contents

Class Configuration

Namespace
BoldSign.Api
Assembly
BoldSign.Api.dll

Represents a set of configuration settings.

public class Configuration : IReadableConfiguration
Inheritance
Configuration
Implements
Derived
Inherited Members

Constructors

Configuration()

Initializes a new instance of the Configuration class.

public Configuration()

Configuration(IDictionary<string, string>, IDictionary<string, string>, IDictionary<string, string>, string)

Initializes a new instance of the Configuration class.

public Configuration(IDictionary<string, string> defaultHeader, IDictionary<string, string> apiKey, IDictionary<string, string> apiKeyPrefix, string basePath = "https://api.boldsign.com")

Parameters

defaultHeader IDictionary<string, string>
apiKey IDictionary<string, string>
apiKeyPrefix IDictionary<string, string>
basePath string

Fields

ApiBaseUrl

Default base URL of the API endpoint.

public const string ApiBaseUrl = "https://api.boldsign.com"

Field Value

string

Default base URL of the API endpoint.

DefaultExceptionFactory

Default creation of exceptions for a given method name and response object.

public static readonly ExceptionFactory DefaultExceptionFactory

Field Value

ExceptionFactory

ISO8601_DATETIME_FORMAT

Identifier for ISO 8601 DateTime Format.

public const string ISO8601_DATETIME_FORMAT = "o"

Field Value

string

Remarks

Version

Version of the package.

public const string Version = "1.0.0"

Field Value

string

Version of the package.

Properties

ApiClient

Gets an instance of an ApiClient for this configuration.

public virtual ApiClient ApiClient { get; set; }

Property Value

ApiClient

BasePath

Gets or sets the base path for API access.

public virtual string BasePath { get; set; }

Property Value

string

BearerToken

Gets or sets the authentication token for OAuth2 authentication as Bearer token in the header.

public virtual string BearerToken { set; }

Property Value

string

The access token.

DateTimeFormat

Gets or sets the date time format used when serializing in the ApiClient By default, it's set to ISO 8601 - "o", for others see: https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx and https://msdn.microsoft.com/en-us/library/8kb3ddd4(v=vs.110).aspx No validation is done to ensure that the string you're providing is valid

public virtual string DateTimeFormat { get; set; }

Property Value

string

The DateTimeFormat string

Default

Gets or sets the default Configuration.

public static Configuration Default { get; set; }

Property Value

Configuration

Configuration.

DefaultHeader

Gets or sets the default header.

public virtual IDictionary<string, string> DefaultHeader { get; set; }

Property Value

IDictionary<string, string>

TempFolderPath

Gets or sets the temporary folder path to store the files downloaded from the server.

public virtual string TempFolderPath { get; set; }

Property Value

string

Folder path.

Timeout

Gets or sets the HTTP timeout (milliseconds) of ApiClient. Default to 100000 milliseconds.

public virtual int Timeout { get; set; }

Property Value

int

UserAgent

Gets or sets the HTTP user agent.

public virtual string UserAgent { get; set; }

Property Value

string

Http user agent.

Methods

AddDefaultHeader(string, string)

Add default header.

public void AddDefaultHeader(string key, string value)

Parameters

key string

Header field name.

value string

Header field value.

SetBearerToken(string)

Sets the authentication token for OAuth2 authentication as Bearer token in the header.

public void SetBearerToken(string accessToken)

Parameters

accessToken string

ToDebugReport()

Returns a string with essential information for debugging.

public static string ToDebugReport()

Returns

string