コード例 #1
0
        public async Task <IActionResult> Index()
        {
            var requestModel = new RandomQuoteRequestModel();
            var rest         = new RestClient.RestClient(new Uri("https://quote-garden.herokuapp.com/api/v2/"));
            var response     = await rest.Request <RandomQuoteResponse>(requestModel);

            return(View(response));
        }
コード例 #2
0
 public BaseModel()
 {
     BibliothecaClient = RestClient.RestClient.CreateClient(Settings.BibliothecaApiEndpoint);
 }