Soap Web service return null value
I want to use a web service for my project and I'm sure web service work properly(I tested in Boomerang - SOAP & REST Client). Web service link is https://api.n11.com/ws/ProductService.wsdl. But when I try get datas from service, service returns null, empty or 0 values. I think VS add web service reference doesn't work correctly, But couldn't find where the problem is.
static async Task<String> GetProductAsyncN11()
{
ServicePointManager.Expect100Continue = true;
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;
var port = new N11ProductServiceReference.ProductServicePortClient();
var requ = new GetProductListRequest();
requ.auth = new N11ProductServiceReference.Authentication();
requ.auth.appKey = "*****";
requ.auth.appSecret = "*****";
requ.pagingData = new N11ProductServiceReference.RequestPagingData();
requ.pagingData.pageSize = 100;
requ.pagingData.currentPage = 0;
var list =await port.GetProductListAsync(requ);
Console.WriteLine(list.GetProductListResponse.products.Rank);
Console.WriteLine("xx" + list.GetProductListResponse.result.status);
Console.WriteLine("xx" + list.GetProductListResponse.products.Length);
foreach (var item in list.GetProductListResponse.products)
{
Console.WriteLine(item.productSellerCode+item.price+item.saleStatus);
}
return "n11";
}
Response is here
Also When I use Boomerang - SOAP & REST Client, here is the response
from Recent Questions - Stack Overflow https://ift.tt/2Szxj2b
https://ift.tt/eA8V8J
Comments
Post a Comment