Add products via API

26 views
Skip to first unread message

Chris Schalenborgh

unread,
Oct 21, 2014, 6:26:02 AM10/21/14
to hippo-c...@googlegroups.com
Hi all,

I'm still new to HippoCMS but need to figure out a couple of questions before we actually adapt HippoCMS.
I was wondering if it's possible too add products to HippoCMS via the API?
Are there any examples online of this API? We're mainly using PHP in our other applications.

Thanks,
Chris

Jeroen Reijn

unread,
Oct 22, 2014, 4:49:28 AM10/22/14
to hippo-c...@googlegroups.com
Hi and welcome!

I have a couple of questions first:

- With 'products' you refer to the product document type shown in our Hippo Go Green demo?
- With API I guess you mean the REST like API we have in the demo?

If both questions are answered with yes then my answer to your question would also be yes.

The Hippo delivery tier (HST) allows you to expose JAX-RS based API endpoints [1]. Some examples can be found in the online demo or Hippo Go Green project as we call it ourselves. I'm not sure if there is a live demo of adding products through the API, but we have code available which you can checkout and learn from once you go into this direction.

To give some further details or background. There are two ways of exposing such a REST API like endpoint.

1. Via a Content based JAX-RS pipeline, which follows a hippo document type based approach to expose content. I'm not sure if we have a piece of code available which demonstrates this.

2. Via a 'plain' based JAX-RS pipeline, which allows you to have full control over the way the API endpoint interacts with your PHP application. An piece of example code for adding products can be found in our public SVN [2].

I hope this answers your questions and do let us me know if you have any other questions!


Cheers,

Jeroen


--
Hippo Community Group: The place for all discussions and announcements about Hippo CMS (and HST, repository etc. etc.)
 
To post to this group, send email to hippo-c...@googlegroups.com
RSS: https://groups.google.com/group/hippo-community/feed/rss_v2_0_msgs.xml?num=50
---
You received this message because you are subscribed to the Google Groups "Hippo Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hippo-communi...@googlegroups.com.
Visit this group at http://groups.google.com/group/hippo-community.
For more options, visit https://groups.google.com/d/optout.



--
Jeroen Reijn
Hippo

Amsterdam - Oosteinde 11, 1017 WT Amsterdam
Boston - 101 Main Street, Cambridge, MA 02142

US +1 877 414 4776 (toll free)
Europe +31(0)20 522 4466
www.onehippo.com

http://about.me/jeroenreijn

Chris Schalenborgh

unread,
Oct 22, 2014, 5:10:56 AM10/22/14
to hippo-c...@googlegroups.com
Hi Jeroen,

Bedankt voor de uitleg.
Is het mogelijk om ons een PHP voorbeeld te sturen van zo’n restful API call? Liefst met JSON..

Bedankt
Chris Schalenborgh | Zaakvoerder
Kryap Internet Services | Thomasboslaan 104/2, 3630 Maasmechelen, Limburg, België
Full service internetbureau gespecialiseerd in het opzetten van alle soorten websites, mobile
& Facebook apps, website hosting, online & e-mail marketing.
Work: +32 89 44 90 27
IM:
kryap.com (Skype)
Web: www.kryap.com
Email: chr...@kryap.com

You received this message because you are subscribed to a topic in the Google Groups "Hippo Community" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/hippo-community/r6t41h3CSKE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to hippo-communi...@googlegroups.com.

Jeroen Reijn

unread,
Oct 22, 2014, 5:30:26 AM10/22/14
to hippo-c...@googlegroups.com
Hi Chris,

thanks for your answer. Do keep in mind that the main language on this list is english, so other people can follow along. I'm by no means an expert in PHP (I've used it at least 10 years ago), but a quick google resulted in this nice example on SO.


To experiment with a piece of JSON you could use to output and URL generated in our public demo:


This page shows you some example calls to do a GET request to get a product or get a list of products. 

To be able to add products you will need to create your own custom JAX-RS endpoint (which should be in Java).

I hope this helps for now.

Jeroen

Reply all
Reply to author
Forward
0 new messages