Jump to content

Do you know Java client for PS REST API?


noemx

Recommended Posts

Hi,

 

I'm thinking about creating a Java client library for PrestaShop REST API I would use under Android and desktop Java applications. Requirements are:

  • Shield the application from XML/JSON specific serialization
  • Lightweight (due to Android use) - Use none or minimum of the 3rd party libraries
  • Fast (due to Android use) - avoid DOM, ...

 

So far I have found just PrestaShopWebService-JavaClient which doesn't fit the bill due to use of DOM, Apache HTTP and exposes raw XML to the user.

 

Do you know of some other library?

 

Thanks

Link to comment
Share on other sites

  • 2 months later...

I haven't found what I was looking for, so I'm currently implementing it. I think I should have a simple prototype able to get any PS resource within a days. Majority of the code will be autogenerated based on the synopsis file.

 

Example:

PrestashopClient client = new PrestashopClient("http://host/api", "token");
Product product = client.getProduct(1);
String ean13 = product.ean13;
String nameLang1 = product.name.get(1);

Is anyone interested in this project? It would be good to run it against different use cases and hear others opinions, so it can mature quickly. I'm planning to share it publicly.

Edited by noemx (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

Hi,
yes, definitely interested.

I have a working implementation but it is incomplete (some entities are lacking, including orders).

I am curious to know how you generate the POJO directly from synopsis, and i would be glad to see and test your implementation, and share what i got. Let me know

Link to comment
Share on other sites

  • 1 month later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...