Skip to content

Instantly share code, notes, and snippets.

View bethkrish's full-sized avatar
💭
AI suggests professionals decide

VijayForVictory bethkrish

💭
AI suggests professionals decide
View GitHub Profile
@bethkrish
bethkrish / APIConsumer.java
Created December 14, 2020 09:27
Example API Client in JAVA - Standalone Application
package io.learn.apiclient;
import java.io.IOException;
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.net.http.HttpResponse.BodyHandlers;
public class APIConsumer {
@bethkrish
bethkrish / APIConsumer.cs
Created December 14, 2020 06:11
Example API Client in C# - Console Application
using System;
using System.Net.Http;
namespace HTTPCall
{
class Program
{
static readonly HttpClient client = new HttpClient();
static async System.Threading.Tasks.Task Main(string[] args)
{