SnapTrade.Net 5.0.79

dotnet add package SnapTrade.Net --version 5.0.79                
NuGet\Install-Package SnapTrade.Net -Version 5.0.79                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SnapTrade.Net" Version="5.0.79" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add SnapTrade.Net --version 5.0.79                
#r "nuget: SnapTrade.Net, 5.0.79"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install SnapTrade.Net as a Cake Addin
#addin nuget:?package=SnapTrade.Net&version=5.0.79

// Install SnapTrade.Net as a Cake Tool
#tool nuget:?package=SnapTrade.Net&version=5.0.79                

SnapTrade.Net - C#

NuGet More Info

Connect brokerage accounts to your app for live positions and trading

Frameworks supported

  • .NET Core >=1.0
  • .NET Framework >=4.6
  • Mono/Xamarin >=vNext

Installation

Using the .NET Core command-line interface (CLI) tools:

dotnet add package SnapTrade.Net

Using the NuGet Command Line Interface (CLI):

nuget install SnapTrade.Net

Using the Package Manager Console:

Install-Package SnapTrade.Net

From within Visual Studio:

  1. Open the Solution Explorer.
  2. Right-click on a project within your solution.
  3. Click on Manage NuGet Packages...
  4. Click on the Browse tab and search for "SnapTrade.Net".
  5. Click on the "SnapTrade.Net" package, select the appropriate version in the right-tab and click Install.

Getting Started

using System;
using System.Collections.Generic;
using System.Diagnostics;
using SnapTrade.Net.Client;
using SnapTrade.Net.Model;

namespace Example
{
    public class GetAccountActivitiesExample
    {
        public static void Main()
        {
            Snaptrade client = new Snaptrade();
            // Configure custom BasePath if desired
            // client.SetBasePath("https://api.snaptrade.com/api/v1");
            client.SetClientId(System.Environment.GetEnvironmentVariable("SNAPTRADE_CLIENT_ID"));
            client.SetConsumerKey(System.Environment.GetEnvironmentVariable("SNAPTRADE_CONSUMER_KEY"));

            var accountId = "accountId_example";
            var userId = "userId_example";
            var userSecret = "userSecret_example";
            var startDate = DateTime.Parse("2013-10-20"); // The start date (inclusive) of the transaction history to retrieve. If not provided, the default is the first transaction known to SnapTrade based on `trade_date`. (optional) 
            var endDate = DateTime.Parse("2013-10-20"); // The end date (inclusive) of the transaction history to retrieve. If not provided, the default is the last transaction known to SnapTrade based on `trade_date`. (optional) 
            var offset = 56; // An integer that specifies the starting point of the paginated results. Default is 0. (optional) 
            var limit = 56; // An integer that specifies the maximum number of transactions to return. Default of 1000. (optional) 
            var type = "BUY,SELL,DIVIDEND"; // Optional comma separated list of transaction types to filter by. SnapTrade does a best effort to categorize brokerage transaction types into a common set of values. Here are some of the most popular values:   - `BUY` - Asset bought.   - `SELL` - Asset sold.   - `DIVIDEND` - Dividend payout.   - `CONTRIBUTION` - Cash contribution.   - `WITHDRAWAL` - Cash withdrawal.   - `REI` - Dividend reinvestment.   - `STOCK_DIVIDEND` - A type of dividend where a company distributes shares instead of cash   - `INTEREST` - Interest deposited into the account.   - `FEE` - Fee withdrawn from the account.   - `OPTIONEXPIRATION` - Option expiration event.   - `OPTIONASSIGNMENT` - Option assignment event.   - `OPTIONEXERCISE` - Option exercise event.   - `TRANSFER` - Transfer of assets from one account to another  (optional) 
            
            try
            {
                // List account activities
                PaginatedUniversalActivity result = client.AccountInformation.GetAccountActivities(accountId, userId, userSecret, startDate, endDate, offset, limit, type);
                Console.WriteLine(result);
            }
            catch (ApiException e)
            {
                Console.WriteLine("Exception when calling AccountInformationApi.GetAccountActivities: " + e.Message);
                Console.WriteLine("Status Code: "+ e.ErrorCode);
                Console.WriteLine(e.StackTrace);
            }
            catch (ClientException e)
            {
                Console.WriteLine(e.Response.StatusCode);
                Console.WriteLine(e.Response.RawContent);
                Console.WriteLine(e.InnerException);
            }
        }
    }
}

Documentation for API Endpoints

All URIs are relative to https://api.snaptrade.com/api/v1

Class Method HTTP request Description
AccountInformationApi GetAccountActivities GET /accounts/{accountId}/activities List account activities
AccountInformationApi GetAllUserHoldings GET /holdings List all accounts for the user, plus balances, positions, and orders for each account.
AccountInformationApi GetUserAccountBalance GET /accounts/{accountId}/balances List account balances
AccountInformationApi GetUserAccountDetails GET /accounts/{accountId} Get account detail
AccountInformationApi GetUserAccountOrders GET /accounts/{accountId}/orders List account recent orders
AccountInformationApi GetUserAccountPositions GET /accounts/{accountId}/positions List account positions
AccountInformationApi GetUserAccountRecentOrders GET /accounts/{accountId}/recentOrders List account recent orders (last 24 hours only)
AccountInformationApi GetUserAccountReturnRates GET /accounts/{accountId}/returnRates List account rate of returns
AccountInformationApi GetUserHoldings GET /accounts/{accountId}/holdings List account holdings
AccountInformationApi ListUserAccounts GET /accounts List accounts
AccountInformationApi UpdateUserAccount PUT /accounts/{accountId} Update details of an investment account
APIStatusApi Check GET / Get API Status
AuthenticationApi DeleteSnapTradeUser DELETE /snapTrade/deleteUser Delete user
AuthenticationApi ListSnapTradeUsers GET /snapTrade/listUsers List all users
AuthenticationApi LoginSnapTradeUser POST /snapTrade/login Generate Connection Portal URL
AuthenticationApi RegisterSnapTradeUser POST /snapTrade/registerUser Register user
AuthenticationApi ResetSnapTradeUserSecret POST /snapTrade/resetUserSecret Rotate user secret
ConnectionsApi DetailBrokerageAuthorization GET /authorizations/{authorizationId} Get connection detail
ConnectionsApi DisableBrokerageAuthorization POST /authorizations/{authorizationId}/disable Force disable connection
ConnectionsApi ListBrokerageAuthorizations GET /authorizations List all connections
ConnectionsApi RefreshBrokerageAuthorization POST /authorizations/{authorizationId}/refresh Refresh holdings for a connection
ConnectionsApi RemoveBrokerageAuthorization DELETE /authorizations/{authorizationId} Delete connection
ConnectionsApi ReturnRates GET /authorizations/{authorizationId}/returnRates List connection rate of returns
ConnectionsApi SessionEvents GET /sessionEvents Get all session events for a user
OptionsApi GetOptionStrategy POST /accounts/{accountId}/optionStrategy Create options strategy
OptionsApi GetOptionsChain GET /accounts/{accountId}/optionsChain Get the options chain for a symbol
OptionsApi GetOptionsStrategyQuote GET /accounts/{accountId}/optionStrategy/{optionStrategyId} Get options strategy quotes
OptionsApi ListOptionHoldings GET /accounts/{accountId}/options List account option positions
OptionsApi PlaceOptionStrategy POST /accounts/{accountId}/optionStrategy/{optionStrategyId}/execute Place an option strategy order
ReferenceDataApi GetCurrencyExchangeRatePair GET /currencies/rates/{currencyPair} Get exchange rate of a currency pair
ReferenceDataApi GetPartnerInfo GET /snapTrade/partners Get Client Info
ReferenceDataApi GetSecurityTypes GET /securityTypes List security types
ReferenceDataApi GetStockExchanges GET /exchanges Get exchanges
ReferenceDataApi GetSymbols POST /symbols Search symbols
ReferenceDataApi GetSymbolsByTicker GET /symbols/{query} Get symbol detail
ReferenceDataApi ListAllBrokerageAuthorizationType GET /brokerageAuthorizationTypes Get all brokerage authorization types
ReferenceDataApi ListAllBrokerages GET /brokerages Get brokerages
ReferenceDataApi ListAllCurrencies GET /currencies Get currencies
ReferenceDataApi ListAllCurrenciesRates GET /currencies/rates Get currency exchange rates
ReferenceDataApi SymbolSearchUserAccount POST /accounts/{accountId}/symbols Search account symbols
TradingApi CancelUserAccountOrder POST /accounts/{accountId}/orders/cancel Cancel order
TradingApi GetOrderImpact POST /trade/impact Check order impact
TradingApi GetUserAccountQuotes GET /accounts/{accountId}/quotes Get symbol quotes
TradingApi PlaceForceOrder POST /trade/place Place order
TradingApi PlaceOrder POST /trade/{tradeId} Place checked order
TransactionsAndReportingApi GetActivities GET /activities Get transaction history for a user
TransactionsAndReportingApi GetReportingCustomRange GET /performance/custom Get performance information for a specific timeframe

Documentation for Models

Dependencies

Author

This C# package is automatically generated by Konfig

Product Compatible and additional computed target framework versions.
.NET net5.0 is compatible.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
5.0.79 53 2/13/2025
5.0.78 70 2/10/2025
5.0.77 48 2/6/2025
5.0.76 70 2/3/2025
5.0.73 98 1/21/2025
5.0.72 52 1/14/2025
5.0.71 65 1/13/2025
5.0.70 79 1/10/2025
5.0.69 63 1/8/2025
5.0.68 77 1/7/2025
5.0.66 133 1/6/2025
5.0.61 475 12/6/2024
5.0.60 102 11/22/2024
5.0.59 113 11/21/2024
5.0.58 113 11/15/2024
5.0.57 95 11/15/2024
5.0.56 92 11/14/2024
5.0.55 101 11/7/2024
5.0.54 92 11/7/2024
5.0.53 108 10/30/2024
5.0.52 89 10/29/2024
5.0.51 91 10/28/2024
5.0.50 97 10/7/2024
5.0.49 99 10/2/2024
5.0.48 105 9/25/2024
5.0.47 112 9/21/2024
5.0.46 156 9/9/2024
5.0.45 120 9/5/2024
5.0.44 111 9/5/2024
5.0.43 95 9/3/2024
5.0.42 135 8/23/2024
5.0.41 140 8/22/2024
5.0.40 113 8/21/2024
5.0.39 116 8/21/2024
5.0.38 125 8/20/2024
5.0.37 127 8/19/2024
5.0.36 136 8/16/2024
5.0.35 122 8/15/2024
5.0.34 131 8/14/2024
5.0.33 84 8/2/2024
5.0.32 92 8/1/2024
5.0.31 115 7/16/2024
5.0.30 107 7/12/2024
5.0.29 123 6/28/2024
5.0.28 115 6/27/2024
5.0.27 106 6/26/2024
5.0.26 131 6/20/2024
5.0.25 505 6/14/2024
5.0.24 107 6/11/2024
5.0.23 112 6/5/2024
5.0.22 103 6/3/2024
5.0.21 131 5/24/2024
5.0.20 1,505 5/21/2024
5.0.19 24,438 5/10/2024
5.0.18 114 5/8/2024
5.0.17 96 5/3/2024
5.0.16 81 5/3/2024
5.0.15 269 4/18/2024
5.0.14 128 4/12/2024
5.0.13 344 4/5/2024
5.0.12 1,661 3/14/2024
5.0.11 113 3/12/2024
5.0.10 120 3/5/2024
5.0.9 401 2/23/2024
5.0.8 134 2/21/2024
5.0.7 118 2/16/2024
5.0.6 137 2/14/2024
5.0.5 130 2/9/2024
5.0.4 111 2/2/2024
5.0.3 365 2/1/2024
5.0.2 122 1/29/2024
5.0.1 117 1/26/2024
5.0.0 406 1/24/2024
4.0.12 842 1/17/2024
4.0.11 121 1/16/2024
4.0.10 243 1/11/2024
4.0.9 160 1/3/2024
4.0.8 449 12/12/2023
4.0.7 196 12/4/2023
4.0.6 156 11/30/2023
4.0.5 147 11/15/2023
4.0.4 151 11/8/2023
4.0.3 156 11/1/2023
4.0.2 185 10/18/2023
4.0.1 196 10/13/2023
4.0.0 186 10/7/2023
3.33.2 240 9/26/2023
3.33.1 195 9/19/2023
3.33.0 2,050 9/2/2023
3.32.1 190 8/31/2023
3.32.0 187 8/16/2023
3.31.0 203 8/14/2023
3.30.0 244 8/11/2023
3.29.0 208 8/9/2023
3.28.0 211 8/9/2023
3.27.0 213 8/4/2023
3.26.0 194 8/2/2023
3.25.0 233 7/31/2023
3.24.0 204 7/27/2023
3.23.0 217 7/27/2023
3.22.0 214 7/18/2023
3.21.0 194 6/22/2023
3.20.0 208 6/13/2023
3.19.0 194 6/7/2023
3.18.0 235 6/5/2023
3.17.0 291 6/1/2023
3.15.0 207 5/29/2023
3.14.0 202 5/26/2023
3.13.0 4,028 5/18/2023
3.12.0 188 5/16/2023
3.11.0 200 5/15/2023
3.10.0 227 5/9/2023
3.9.0 509 4/28/2023
3.8.0 239 4/28/2023
3.7.0 412 4/23/2023
3.6.0 205 4/21/2023
3.5.0 230 4/20/2023
3.4.0 223 4/18/2023
3.3.0 234 4/17/2023
3.2.0 249 4/15/2023
3.1.0 235 4/15/2023
3.0.0 251 4/12/2023
2.0.0 260 4/11/2023
1.3.0 275 4/6/2023
1.2.0 259 4/6/2023
1.1.0 280 4/6/2023
1.0.0 278 4/6/2023

Minor update