Click here to Skip to main content
15,891,431 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i am having trouble configuring this API https://pipl.com/dev/

i have this code in page load event, but the problem is that it keep on loading the page once i click on "veiw page in browser".

C#
protected void Page_Load(object sender, EventArgs e)
{
    RunAsync().Wait();
}
static async Task RunAsync()
{
    SearchAPIRequest req = new SearchAPIRequest(email: "clark.kent@example.com");

    SearchAPIResponse resp = await req.SendAsync();
    Console.Out.WriteLine(resp.Image.GetThumbnailUrl(200, 100, true, true));
    Console.Out.WriteLine(resp.Name);
    Console.Out.WriteLine(resp.Education);
    Console.Out.WriteLine(resp.Username);
    Console.Out.WriteLine(resp.Address);

    var jobs = resp.Person.Jobs.Select(j => j.ToString());
    Console.Out.WriteLine(String.Join(", ", jobs));
    Console.Out.WriteLine();

    var relationships = resp.Person.Relationships.Select(r => r.Names[0]);
    Console.Out.WriteLine(String.Join(", ", relationships));

    Console.Out.WriteLine();

}

Am i missing some code ? or any thing else.. please guide.

PS: I have already installed their package with "PM> Install-Package piplclient"
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900