File tree Expand file tree Collapse file tree 3 files changed +21
-3
lines changed
Expand file tree Collapse file tree 3 files changed +21
-3
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,7 @@ public class ApiConnection
3030 {
3131 private readonly static JsonSerializerSettings _jsonSettings = new ( ) { Converters = { new LiveAlgorithmResultsJsonConverter ( ) , new OrderJsonConverter ( ) } } ;
3232
33+ /// <summary>
3334 /// Authorized client to use for requests.
3435 /// </summary>
3536 public RestClient Client ;
Original file line number Diff line number Diff line change 1- /*
1+ /*
22 * QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals.
33 * Lean Algorithmic Trading Engine v2.0. Copyright 2014 QuantConnect Corporation.
44 *
1313 * limitations under the License.
1414*/
1515using System ;
16- using System . Collections . Generic ;
1716using Newtonsoft . Json ;
17+ using System . Collections . Generic ;
1818
1919namespace QuantConnect . Api
2020{
@@ -52,6 +52,12 @@ public class Project : RestResponse
5252 /// </summary>
5353 [ JsonProperty ( PropertyName = "language" ) ]
5454 public Language Language { get ; set ; }
55+
56+ /// <summary>
57+ /// The projects owner id
58+ /// </summary>
59+ [ JsonProperty ( PropertyName = "ownerId" ) ]
60+ public int OwnerId { get ; set ; }
5561 }
5662
5763 /// <summary>
@@ -65,4 +71,4 @@ public class ProjectResponse : RestResponse
6571 [ JsonProperty ( PropertyName = "projects" ) ]
6672 public List < Project > Projects { get ; set ; }
6773 }
68- }
74+ }
Original file line number Diff line number Diff line change @@ -29,6 +29,17 @@ namespace QuantConnect.Tests.API
2929 [ TestFixture , Explicit ( "Requires configured api access and available backtest node to run on" ) ]
3030 public class ProjectTests : ApiTestBase
3131 {
32+ [ Test ]
33+ public void ReadProject ( )
34+ {
35+ var readProject = ApiClient . ReadProject ( 16408347 ) ;
36+ Assert . IsTrue ( readProject . Success ) ;
37+ Assert . AreEqual ( 1 , readProject . Projects . Count ) ;
38+
39+ var project = readProject . Projects [ 0 ] ;
40+ Assert . AreNotEqual ( 0 , project . OwnerId ) ;
41+ }
42+
3243 /// <summary>
3344 /// Test creating and deleting projects with the Api
3445 /// </summary>
You can’t perform that action at this time.
0 commit comments