コード例 #1
0
ファイル: Client.cs プロジェクト: maincoon/CoinsPaidClient
        /// <summary>
        /// Ping API as described in configuration
        /// </summary>
        /// <returns>true if API available otherwise false</returns>
        public async Task <bool> Ping(CancellationToken cancel = default)
        {
            using (HttpClient http = new HttpClient()) {
                var response = await HTTPHelper.GetRequestAsync(Config.Endpoint + "/ping", http, cancel);

                return(response.Code == HttpStatusCode.OK);
            }
        }