C# SDK
Install and start using the C# SDK.
Intro
The The Plaid API SDK provides access to the The Plaid API REST APIs.
The Plaid REST API. Please see https://plaid.com/docs/api for more details.
Installation
To add the SDK to your project from NuGet:
dotnet add package ApimaticplaidSDKTo build against the SDK source instead, add it as a project reference into your solution:
dotnet add reference <path-to-sdk>/ThePlaidApi.csprojQuick Start
Dependency Injection
Register the client with IServiceCollection and resolve it from the container. The HttpClient is managed by IHttpClientFactory. Configure the client's behavior through ThePlaidApiClientOptions.
services.AddThePlaidApiClient(options =>
{
options.PlaidClientId = "YOUR_API_KEY";
options.PlaidSecret = "YOUR_API_KEY";
options.PlaidVersion = "YOUR_API_KEY";
options.Environment = ServerEnvironment.Production;
// TODO: configure more client options here
});Direct Instantiation
Create the client by passing an HttpClient you manage yourself. Configure the client's behavior through ThePlaidApiClientOptions.
var httpClient = new HttpClient();
// TODO: configure more client options here
var options = new ThePlaidApiClientOptions
{
PlaidClientId = "YOUR_API_KEY",
PlaidSecret = "YOUR_API_KEY",
PlaidVersion = "YOUR_API_KEY",
Environment = ServerEnvironment.Production,
};
var client = new ThePlaidApiClient(httpClient, options);
