eBay API addItem returns error - <Item.Country> is invalid or missing - ebay-api

I'm totally new to ebay api. I tried to use addItem api call, I stopped with this error.
`
eBay returned the following error(s):
37 : Input data is
invalid.Input data for tag <Item.Country> is invalid or
missing. Please check API documentation.
I've given all of their inputs and used their example (addItem code) only.
Site ID is 3 (UK) and currencyID="GBP"

See the link http://developer.ebay.com/devzone/xml/docs/reference/ebay/types/CountryCodeType.html.
Country Code for UK is GB.
So, your xml will be <Country>GB</Country>

Related

Unable to POST NZ employee openingBalances to Xero?

I am attempting to create a single opening balances record against an existing employee but keep getting a 400 Bad Request response with this detail...
At least one NZ opening balance item is required in the request
I am following the instructions as per this documentation...
https://developer.xero.com/documentation/api/payrollnz/employeeopeningbalances#post-opening-balances
URL : {DestinationID} is properly replaced with the employee GUIDhttps://api.xero.com/payroll.xro/2.0/employees/{DestinationID}/openingBalances
JSON Body[{"periodEndDate":"2011-01-30T00:00:00","daysPaid":5.00,"unpaidWeeks":0.00,"grossEarnings":1442.31}]
The Xero forums and support is pretty unreliable so I'm posting here in the hopes for a better response.
After some trial and error using the API Explorer that Xero provides I was able to get it working using their example....
I eventually learned that daysPaid and unpaidWeeks must both be integer whole numbers or else it fails.... The error message provided is misleading but this resolves the problem.

Shopify collect orders with rest API error

I am trying to get the Shopify orders list with the latest version of rest pagination API. There are totally of 1000 orders. I set a limit of 200. First page of API hit is working properly. While I am hitting the second page with page info I am getting error as below. Can you help me please regarding this.
Rest API URL: GET https://the-commerce-shop-1.myshopify.com/admin/api/2020-01/orders.json?limit=200&page_info=eyJzdGF0dXMiOiJhbnkiLCJsYXN0X2lkIjoxODY4Njk3NjY1NTkxLCJsYXN0X3ZhbHVlIjoiMjAxOS0xMS0yNSAwOTozNjo1OSIsImRpcmVjdGlvbiI6Im5leHQifQ&status=any
Error: Message: Client error: GET https://the-commerce-shop-1.myshopify.com/admin/api/2020-01/orders.json?limit=200&page_info=eyJzdGF0dXMiOiJhbnkiLCJsYXN0X2lkIjoxODY4Njk3NjY1NTkxLCJsYXN0X3ZhbHVlIjoiMjAxOS0xMS0yNSAwOTozNjo1OSIsImRpcmVjdGlvbiI6Im5leHQifQ&status=any resulted in a 400 Bad Request response:\n{\"errors\":{\"status\":\"status cannot be passed when page_info is present. See https:\/\/help.shopify.com\/api\/guides\/pag (truncated...)\n, Line: 113"
First you ask for orders with nothing but the status you want and a limit. That initates the paging.
Once you are through your first 200 orders, you no longer call the endpoint with status or limit, you simply use paging.
That works.

Error 400 Nothing to geocode with Openweathermap API

I am trying to use openweathermap for my python app but there is a problem. I do a simple request to this link: http://api.openweathermap.org/data/2.5/weather?q=London,fr&appid=[My Key]
I get an error 400 with the message Nothing to geocode.
Do you know what it means?
The reason that it's giving you an error is because you're asking the API for data on London, France (q=London,fr). The fr part is the country code.
All you have to do is change fr to uk and you should be set! The link would be http://api.openweathermap.org/data/2.5/weather?q=London,uk&appid=[yourID]
You have to add the lat and lon after the URL and then add your API key, then it will work:
https://api.openweathermap.org/data/2.5/weather?lat=35&lon=139&APPID=YOUR_API_KEY
You may also input the lat and long of the location and try to build again.
api.openweathermap.org/data/2.5/weather?lat=35&lon=139
Like This ^

Need To Resolve Yelp API Response Error: “Signature is invalid”

My issue is when I try and fetch the Yelp API I keep getting this error time after time and i'm not sure why i've checked all the parameters and still cant get anything back from Yelp
My Yelp API Fetch Link -
https://api.yelp.com/v2/search?term=food&ll=37.788022,-122.399797&oauth_consumer_key=MY_Consumer_Key&oauth_token=MY_TOKEN&oauth_signature_method=HMAC-SHA1&oauth_signature=TOKEN_SECRET&oauth_timestamp=1456337018&oauth_nonce=1456337018
My Error -
error: {
text: "Signature was invalid",
id: "INVALID_SIGNATURE",
description: "Invalid signature. Expected signature base string:
GET&https%3A%2F%2Fapi.yelp.com%2Fv2%2Fsearch&ll%3D37.788022%252C-122.399797%26oauth_consumer_key%3DG02O6tXnFkSbsGYOJxCQDw%26oauth_nonce%3D1456337018%26oauth_signature_method%3DHMAC-SHA1%26oauth_timestamp%3D1456337018%26oauth_token%3DBPMpqKrD4dA4xGGHKtC_-xitzb5LRNn8%26term%3Dfood"
}
Error in your API call url,yelp using oauth 1.0a,Which one url parameters should be in alphabet order(this one is telling clearly in your error description), So API call url should be like this:
https://api.yelp.com/v2/search?ll=37.788022,-122.399797&oauth_consumer_key=MY_Consumer_Key&oauth_nonce=1456337018&oauth_signature=TOKEN_SECRET&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1456337018&oauth_token=MY_TOKEN&term=food

I am trying to use Yodlee/executeUserSearchRequest as a RESTful request and need an answer on how to call

I am working with the Yodlee services in c# and using the RESTful api. So far I have successfully connected and logged in with my CobrandSession and UserSessionToken in the development environment. I used the sample apps provided in c# and with some advice from shreyans i got an app working. What I got working was
1) Get YodleeAuthentication
2) Get UserAuthentication
3) Get ItemSummaries
I am now trying to get the full transaction details for each of the Items (i.e. collections of accounts that are an Item)
reading the Docs here https://developer.yodlee.com/Indy_FinApp/Aggregation_Services_Guide/REST_API_Reference/executeUserSearchRequest it states that I need to call executeUserSearchRequest and then paginate through the results using the getUserTransactions. So I am stuck at this point. I dont really want a search which has parameters I just want ALL transactions for this account that I can see.
However, I am using the variables as defined in that page :-
var request = new RestRequest("/jsonsdk/TransactionSearchService/executeUserSearchRequest", Method.POST);
request.AddParameter("cobSessionToken", param.CobSessionToken);
request.AddParameter("userSessionToken", param.UserSessionToken);
request.AddParameter("transactionSearchRequest.containerType", param.ContainerType);
request.AddParameter("transactionSearchRequest.higherFetchLimit", param.HigherFetchLimit);
request.AddParameter("transactionSearchRequest.lowerFetchLimit", param.LowerFetchLimit);
request.AddParameter("transactionSearchRequest.resultRange.endNumber", param.EndNumber);
request.AddParameter("transactionSearchRequest.resultRange.startNumber", param.StartNumber);
request.AddParameter("transactionSearchRequest.searchFilter.currencyCode", param.CurrencyCode);
request.AddParameter("transactionSearchRequest.searchFilter.postDateRange.fromDate", param.FromDate);
request.AddParameter("transactionSearchRequest.searchFilter.postDateRange.toDate", param.ToDate);
request.AddParameter("transactionSearchRequest.searchFilter.transactionSplitType.splitType", param.SplitType);
request.AddParameter("transactionSearchRequest.ignoreUserInput", param.IgnoreUserInput);
request.AddParameter("transactionSearchRequest.searchFilter.itemAcctId", param.ItemAcctId);
var response = RestClientUtil.GetBase().Execute(request);
var content = response.Content;
return new YodleeServiceResultDto(content);
As per the response from shreyans in this posting Getting Error "Any one of [**] of transactionSearchFilter cannot be NULL OR Invalid Values I am not putting in the ClientId and the ClientName
The documentation doesn't specify the format of the dates but the example seems to tell me that its american date format. And specifies a parameter saying IgnoreUserinput, but doesnt have a parameter for user input so this is confusing
When I make a call using this format I get an error response
var getSearchResult = yodleeExecuteUserSearchRequest.Go(yodleeExecuteUserSearchRequestDto);
getSearchResult.Result="
{"errorOccured":"true","exceptionType":"Exception Occured","refrenceCode":"_60ecb1d7-a4c4-4914-b3cd-49182518ca5d"}"
But I get no error message in this and I have no idea what I have done wrong or where to look up this error, can somebody who has used Yodlee REST Api point me in the right direction as I need to get this researched quickly....
thanks your your help, advice, corrections and pointers....
Here is the list of parameters which you can try
1) For a specific ItemAccountId all transactions
transactionSearchRequest.containerType=all
transactionSearchRequest.higherFetchLimit=500
transactionSearchRequest.lowerFetchLimit=1
transactionSearchRequest.resultRange.startNumber=1
transactionSearchRequest.resultRange.endNumber=500
transactionSearchRequest.searchClients.clientId=1
transactionSearchRequest.searchClients.clientName=DataSearchService
transactionSearchRequest.searchFilter.currencyCode=USD
transactionSearchRequest.searchClients=DEFAULT_SERVICE_CLIENT
transactionSearchRequest.ignoreUserInput=true
transactionSearchRequest.ignoreManualTransactions=false
transactionSearchRequest.searchFilter.transactionSplitType=ALL_TRANSACTION
transactionSearchRequest.searchFilter.itemAccountId.identifier=10000353
2) For a Specific account (itemAccountId) with start and end dates
transactionSearchRequest.containerType=all
transactionSearchRequest.higherFetchLimit=500
transactionSearchRequest.lowerFetchLimit=1
transactionSearchRequest.resultRange.startNumber=1
transactionSearchRequest.resultRange.endNumber=500
transactionSearchRequest.searchClients.clientId=1
transactionSearchRequest.searchClients.clientName=DataSearchService
transactionSearchRequest.searchFilter.currencyCode=USD
transactionSearchRequest.searchClients=DEFAULT_SERVICE_CLIENT
transactionSearchRequest.ignoreUserInput=true
transactionSearchRequest.ignoreManualTransactions=false
transactionSearchRequest.searchFilter.transactionSplitType=ALL_TRANSACTION
transactionSearchRequest.searchFilter.itemAccountId.identifier=10000353
transactionSearchRequest.searchFilter.postDateRange.fromDate=08-01-2013
transactionSearchRequest.searchFilter.postDateRange.toDate=10-31-2013