Description
The ListStores API allows the Account Owner to retrieve a list of all the Stores that were previously created.
Note that when a trial account is first created, you will see the DefaultStore listed automatically. The trial account is limited to a single store however the DefaultStore can be deleted and another store created with a different name if desired.
Specific Request Parameters
(Refer to Common Request Parameters)
Specific Response Elements
(Refer to Common Response Elements)
The following specific "result" element is a child of the common root element "response" and a sibling of the common "metadata" element:
{ "result": { "stores": [{"name": "name of a store"},{"name": "name of another store"}] } }
Specific Logical Errors
(Refer to Common Logical Error Codes)
Examples
Sample Request
Request URL: http://sandbox.apstrata.com/apsdb/rest/[authenticationkey]/ListStores?apsws.time=[timestamp]&apsws.authSig=[signature]
POST parameters: [None]
Sample XML Response
Success XML:
<response xmlns="http://www.apstrata.com/services/schemas/apstrata_database_response.xsd"> <metadata> <requestId>xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx</requestId> <status>success</status> </metadata> <result> <stores> <store name="store1"></store> <store name="store2"></store> </stores> </result> <response>
Failure XML:
<response xmlns="http://www.apstrata.com/services/schemas/apstrata_database_response.xsd"> <metadata> <requestId>xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx</requestId> <status>failure</status> <errorCode>[errorCode]</errorCode> <errorDetail>[failMsg]</errorDetail> </metadata> </response>
Sample JSON Response
{"response": { "metadata": { "requestId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "status": "success" }, "result": { "stores": [ { "name": "store1" }, { "name": "store2" } ] } }}