ebay - ebaysdk-python Authentication failed : Invalid Application -
i trying connect ebay python script. here code, have used ebaysdk-python
import ebaysdk ebaysdk.finding import connection finding ebaysdk.exception import connectionerror try: api = finding(debug=true, config_file='myebay.yaml',) api_request = { 'keywords':'harry potter', 'maxentries': 2, 'availableitemsonly':true, } response = api.execute('finditemsadvanced', api_request) print response except connectionerror e: print "\n\n\n",e print "\n\n\n",e.response.dict()
while running getting below error. here debug result
2015-08-25 12:24:18,101 ebaysdk [debug]:execute: verb=finditemsadvanced data={'keywords': 'harry potter', 'maxentries': 2, 'availableitemsonly': true} 2015-08-25 12:24:18,107 ebaysdk [debug]:request (cb3019a4-1f9a-4e82-9ba9-b45ed84329dd): post http://svcs.ebay.com/services/search/findingservice/v1 2015-08-25 12:24:18,107 ebaysdk [debug]:headers=caseinsensitivedict({'x-ebay-soa-global-id': 'ebay-us', 'content-length': '254', 'x-ebay-soa-security-appname': u'test-08c4-473a-8461-415f8024798f', 'x-ebay-soa-operation-name': 'finditemsadvanced', 'x-ebay-soa-service-name': 'findingservice', 'x-ebay-soa-service-version': u'1.0.0', 'user-agent': 'ebaysdk/2.1.2 python/2.7.6 linux/3.16.0-46-generic', 'x-ebay-sdk-request-id': 'cb3019a4-1f9a-4e82-9ba9-b45ed84329dd', 'x-ebay-soa-response-data-format': 'xml', 'x-ebay-soa-request-data-format': 'xml', 'content-type': 'text/xml'}) 2015-08-25 12:24:18,107 ebaysdk [debug]:body=<?xml version='1.0' encoding='utf-8'?><finditemsadvancedrequest xmlns="http://www.ebay.com/marketplace/search/v1/services"><availableitemsonly>true</availableitemsonly><keywords>harry potter</keywords><maxentries>2</maxentries></finditemsadvancedrequest> 2015-08-25 12:24:18,809 ebaysdk [debug]:response (cb3019a4-1f9a-4e82-9ba9-b45ed84329dd): 2015-08-25 12:24:18,809 ebaysdk [debug]:elapsed time=0:00:00.701135 2015-08-25 12:24:18,809 ebaysdk [debug]:status code=500 2015-08-25 12:24:18,809 ebaysdk [debug]:headers=caseinsensitivedict({'x-ebay-soa-global-id': 'ebay-us', 'x-ebay-request-id': '14f63a2c-ffb0-a7ea-3304-9134ce2175ca!services.search.findingservice.v1!10.126.163.48!fndngesb[]', 'x-cnection': 'close', 'x-ebay-soa-operation-name': 'finditemsadvanced', 'transfer-encoding': 'chunked', 'x-ebay-soa-error-response': 'true', 'x-ebay-soa-service-name': '{http://www.ebay.com/marketplace/search/v1/services}findingservice', 'x-ebay-soa-service-version': '1.13.0', 'server': 'apache-coyote/1.1', 'x-ebay-soa-locale-list': 'en-us_us', 'x-ebay-soa-message-protocol': 'none', 'date': 'tue, 25 aug 2015 06:54:17 gmt', 'x-ebay-soa-request-id': '14f63a2d-0360-a7ed-d744-9224fd474628!findingservice!10.126.221.116!v3apifindingcore[]', 'guid': '14f63a2c-ffb0-a7ea-3304-9134ce2175ca', 'content-type': 'text/xml;charset=utf-8', 'x-ebay-soa-response-data-format': 'xml', 'x-ebay-soa-service-metrics': '4251324'}) 2015-08-25 12:24:18,809 ebaysdk [debug]:content=<?xml version='1.0' encoding='utf-8'?><errormessage xmlns="http://www.ebay.com/marketplace/search/v1/services"><error><errorid>11002</errorid><domain>security</domain><severity>error</severity><category>system</category><message>authentication failed : invalid application: test-08c4-473a-8461-415f8024798f</message><subdomain>authentication</subdomain><parameter name="param1">invalid application: test-08c4-473a-8461-415f8024798f</parameter></error></errormessage> 2015-08-25 12:24:18,810 ebaysdk [error]:finditemsadvanced: internal server error, domain: security, severity: error, errorid: 11002, authentication failed : invalid application: test-08c4-473a-8461-415f8024798f u'finditemsadvanced: internal server error, domain: security, severity: error, errorid: 11002, authentication failed : invalid application: test-08c4-473a-8461-415f8024798f' {'errormessage': {'error': {'category': 'system', 'domain': 'security', 'severity': 'error', 'message': 'authentication failed : invalid application: test-08c4-473a-8461-415f8024798f', 'subdomain': 'authentication', 'parameter': {'value': 'invalid application: test-08c4-473a-8461-415f8024798f', '_name': 'param1'}, 'errorid': '11002'}}}
any guess? missing?
thanks in advance.
you calling ebay api production environment. need call sandbox credential. credential may correct need change domain. ebaysdk-python api default calling production environment.
change line passing ebay sandbox endpoint in domain.
api = finding(domain='svcs.sandbox.ebay.com', debug=true, config_file='myebay.yaml')
it give response ack success,
hope helps.
Comments
Post a Comment