Пример #1
0
        private static async Task RemoteApiCall2()
        {
            const string BASE_URL = "https://api4all.azurewebsites.net";

            using (var httpClient = new HttpClient())
            {
                var client = new swaggerClient(BASE_URL, httpClient);
                var items  = await client.StudentsAllAsync();

                foreach (var i in items)
                {
                    Console.WriteLine($"{i.StudentId}\t{i.FirstName}\t{i.LastName}\t{i.School}");
                }
            }
        }