コード例 #1
0
        public async Task GetMeta()
        {
            var client = new PsawClient();
            var meta   = await client.GetMeta();

            Assert.True(meta.ClientAcceptsJson);
        }
コード例 #2
0
        public async Task ProxyUsage()
        {
            var client = new PsawClient(new RequestsManagerOptions
            {
                ProxyAddress = "178.217.194.175:49850"
            });

            var meta = await client.GetMeta();

            Assert.Equal("178.217.194.175", meta.SourceIp);
            Assert.Equal("PL", meta.ClientRequestHeaders.CfIpCountry);
        }