question

preferredmart avatar image
0 Likes"
preferredmart asked ·

Invalid URI: The Authority/Host could not be parsed

getting this error when trying to make a api call
trading api
10 |600 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

preferredmart avatar image
0 Likes"
preferredmart answered ·
it's the Trading API, here's the code i use and i'm facing this error when he tries to perform the apicall.Execute(); call //create the context ApiContext context = new ApiContext(); //set the User token context.ApiCredential.eBayToken = eBayTradingAPI.Properties.Settings.Default.Prod_token; //set the server url // context.SoapApiServerUrl = " https://api.sandbox.ebay.com/wsapi";; context.SoapApiServerUrl = " https://api.ebay.com/wsapi";; //enable logging context.ApiLogManager = new ApiLogManager(); context.ApiLogManager.ApiLoggerList.Add(new FileLogger(" log.txt", true, true, true)); context.ApiLogManager.EnableLogging = true; //set the version context.Version = "705"; context.Site = SiteCodeType.US; //Create the call and set the fields CompleteSaleCall apicall = new CompleteSaleCall(context); //Either ItemID-TransactionID or OrderLineItemID or OrderID is required. If item is part of an order, specify OrderID. apicall.OrderLineItemID = "123456"; apicall.Shipped = true; apicall.Shipment = new ShipmentType(); apicall.Shipment.ShipmentTrackingDetails = new ShipmentTrackingDetailsTypeCollection(); ShipmentTrackingDetailsType shpmnt = new ShipmentTrackingDetailsType(); shpmnt.ShipmentTrackingNumber = "1z1234586789"; shpmnt.ShippingCarrierUsed = "UPS"; apicall.Shipment.ShipmentTrackingDetails.Add(shpmnt); //Specify time in GMT. This is an optional field //If you don't specify a value for the ShippedTime, it will be defaulted to the time at which the call was made apicall.Shipment.ShippedTime = new DateTime(2011, 3, 5, 10, 0, 0).ToUniversalTime(); //call the Execute method apicall.Execute(); //Console.WriteLine(apicall.ApiResponse.Ack);
· Share
10 |600 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

devanathan.developersupport@ebay.com avatar image
0 Likes"
devanathan.developersupport@ebay.com answered ·
Hello preferredmart, Could you please let us know which API call returned the error you mentioned? If possible share the request and response XMLs. Please ensure that you remove any authorization token from the XML before sharing. Thanks Best Regards, SAMPATH Devanathan eBay Developer Support
· Share
10 |600 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.