Created
January 13, 2017 02:22
-
-
Save scottksmith95/6233a36532a1a4897401e82b31c74490 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using Newtonsoft.Json; | |
class Program | |
{ | |
const string GitHubPath = "https://api.github.com/users/scottksmith95/repos"; | |
static void Main(string[] args) | |
{ | |
var gitHubUri = new Uri(GitHubPath); | |
var json = ApiRequest.GetJson(gitHubUri); | |
var jsonObject = JsonConvert.DeserializeObject<List<GitHubRepo>>(json); | |
} | |
} | |
public class Owner | |
{ | |
public string avatar_url { get; set; } | |
public string login { get; set; } | |
public string url { get; set; } | |
public string gravatar_id { get; set; } | |
public int id { get; set; } | |
} | |
public class GitHubRepo | |
{ | |
public string description { get; set; } | |
public bool has_wiki { get; set; } | |
public string svn_url { get; set; } | |
public int open_issues { get; set; } | |
public string language { get; set; } | |
public int watchers { get; set; } | |
public bool fork { get; set; } | |
public string homepage { get; set; } | |
public string git_url { get; set; } | |
public string clone_url { get; set; } | |
public string pushed_at { get; set; } | |
public int size { get; set; } | |
public bool @private { get; set; } | |
public string created_at { get; set; } | |
public string html_url { get; set; } | |
public Owner owner { get; set; } | |
public string name { get; set; } | |
public string url { get; set; } | |
public object mirror_url { get; set; } | |
public bool has_downloads { get; set; } | |
public bool has_issues { get; set; } | |
public string ssh_url { get; set; } | |
public string updated_at { get; set; } | |
public int id { get; set; } | |
public int forks { get; set; } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment