Lean  $LEAN_TAG$
Account.cs
1 /*
2  * QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals.
3  * Lean Algorithmic Trading Engine v2.0. Copyright 2014 QuantConnect Corporation.
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14 */
15 
16 using System;
17 using Newtonsoft.Json;
18 
19 namespace QuantConnect.Api
20 {
21  /// <summary>
22  /// Account information for an organization
23  /// </summary>
24  public class Account : RestResponse
25  {
26  /// <summary>
27  /// The organization Id
28  /// </summary>
29  [JsonProperty(PropertyName = "organizationId")]
30  public string OrganizationId { get; set; }
31 
32  /// <summary>
33  /// The current account balance
34  /// </summary>
35  [JsonProperty(PropertyName = "creditBalance")]
36  public decimal CreditBalance { get; set; }
37 
38  /// <summary>
39  /// The current organizations credit card
40  /// </summary>
41  [JsonProperty(PropertyName = "card")]
42  public Card Card { get; set; }
43  }
44 
45  /// <summary>
46  /// Credit card
47  /// </summary>
48  public class Card
49  {
50  /// <summary>
51  /// Credit card brand
52  /// </summary>
53  [JsonProperty(PropertyName = "brand")]
54  public string Brand { get; set; }
55 
56  /// <summary>
57  /// The credit card expiration
58  /// </summary>
59  [JsonProperty(PropertyName = "expiration")]
60  [JsonConverter(typeof(Time.MonthYearJsonConverter))]
61  public DateTime Expiration { get; set; }
62 
63  /// <summary>
64  /// The last 4 digits of the card
65  /// </summary>
66  [JsonProperty(PropertyName = "last4")]
67  public decimal LastFourDigits { get; set; }
68  }
69 }