SlideShare a Scribd company logo
eZ Publish REST v2 calls made easy
Apigee Console & eZ Publish REST
06/06/2013Presenter: Łukasz Serwatka Slide 2
APIGEE console & eZ Publish REST
Presenter
Łukasz Serwatka
Product Management Technical Lead
lukasz.serwatka@ez.no
@lserwatka
 Working with eZ since 1st of March 2005
 Over 10 years of experience with eZ Publish
 Former member of the Engineering team, now in the Product Management
 eZ Publish & Polish PHP Community Member
 Expert in the mobile solutions (mobile applications & mobile strategies)
06/06/2013Presenter: Łukasz Serwatka Slide 3
APIGEE console & eZ Publish REST
Console To-Go
 The Apigee “eZ Publish” API console makes it easy to learn, test, and debug
the eZ Publish REST v2 API with interactive tools and documentation.
06/06/2013Presenter: Łukasz Serwatka Slide 4
APIGEE console & eZ Publish REST
API Providers
06/06/2013Presenter: Łukasz Serwatka Slide 5
APIGEE console & eZ Publish REST
Console To-Go
 Apigee Console To-Go describes the API using the Web Application
Description Language (WADL). By uploading API description to Apigee a new
custom Console can be created that allows to customize the look and feel,
and then embed API Console on your own developer portal.
 Console can display all methods available to developers, organized into the
groups. Developers can browse the methods, reading the descriptions
provided for each method and parameter, and see what information is
required for each request, what authentication mechanisms are supported,
and what parameters are optional or required. More importantly, developers
can use the Console to enter authentication credentials and easily test
requests and see what responses are returned.
06/06/2013Presenter: Łukasz Serwatka Slide 6
APIGEE console & eZ Publish REST
Console To-Go: Name Your Console
 Visit https://apigee.com/togo to setup a new console
06/06/2013Presenter: Łukasz Serwatka Slide 7
APIGEE console & eZ Publish REST
Console To-Go: Set Credentials
06/06/2013Presenter: Łukasz Serwatka Slide 8
APIGEE console & eZ Publish REST
Console To-Go: Describe Your API
06/06/2013Presenter: Łukasz Serwatka Slide 9
APIGEE console & eZ Publish REST
What is WADL?
 The Web Application Description Language (WADL) is an XML-based file
format that provides a machine-readable description of HTTP-based web
APIs. A WADL file defines the "resources" (that is, URIs) that constitute an
API. For each resource, WADL defines one or more "methods" that act on
those resources. With RESTful APIs, a 'method' is a combination of a
resource (URI) and the HTTP verb (most commonly GET, PUT, POST and
DELETE) that acts on the resource. WADL in its simplest form defines create,
read, update and delete actions (sometimes referred to as CRUD operations)
on resources defined by the API.
06/06/2013Presenter: Łukasz Serwatka Slide 10
APIGEE console & eZ Publish REST
Resources
 An example eZ Publish API that defines 3 resources: objects, locations, and
sections.
 http://api.example.com/api/ezp/v2/content/objects
 http://api.example.com/api/ezp/v2/content/locations
 http://api.example.com/api/ezp/v2/content/sections
06/06/2013Presenter: Łukasz Serwatka Slide 11
APIGEE console & eZ Publish REST
Resources
 Application definition
<application xmlns:xsi="http://www.w3.org/2001/XMLSchema-
instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:apigee="http://api.apigee.com/wadl/2010/07/"
xmlns="http://wadl.dev.java.net/2009/02"
xsi:schemaLocation="http://wadl.dev.java.net/2009/02
http://apigee.com/schemas/wadl-schema.xsd
http://api.apigee.com/wadl/2010/07/
http://apigee.com/schemas/apigee-wadl-extensions.xsd">
<!-- Base defines the domain and base path of the endpoint --
>
<resources base="http://api.demo.ez.no/api/ezp/v2">
</resources>
</application>
06/06/2013Presenter: Łukasz Serwatka Slide 12
APIGEE console & eZ Publish REST
Resources
 Resource definition
<application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:apigee="http://api.apigee.com/wadl/2010/07/"
xmlns="http://wadl.dev.java.net/2009/02"
xsi:schemaLocation="http://wadl.dev.java.net/2009/02
http://apigee.com/schemas/wadl-schema.xsd
http://api.apigee.com/wadl/2010/07/ http://apigee.com/schemas/apigee-
wadl-extensions.xsd">
<!-- Base defines the domain and base path of the endpoint -->
<resources base="http://api.demo.ez.no/api/ezp/v2">
<!-- A resource with a GET method that requires a template
parameter and a header -->
<resource path="/content/objects/{contentId}">
</resource>
</resources>
</application>
06/06/2013Presenter: Łukasz Serwatka Slide 13
APIGEE console & eZ Publish REST
Resources
 For each resource, developers need a way to create, to read, to update, and
to delete each resource--in other words, a set of methods is required for each
resource.
RESTful APIs usually define a:
 POST method (for creating an article)
 PUT method (for modifying an existing article)
 GET method (for retrieving the article)
 DELETE method (for removing articles)
06/06/2013Presenter: Łukasz Serwatka Slide 14
APIGEE console & eZ Publish REST
Resources
 A single GET method on the /content/objects resource. The method returns a
list of content objects.
<method id="get-content-objects" name="GET"
apigee:displayName="content/objects">
<apigee:tags>
<apigee:tag primary="true">Content Resources</apigee:tag>
</apigee:tags>
<apigee:authentication required="true"/>
<apigee:example url="/content/objects"/>
<doc
apigee:url="http://api.mydomain.com/doc/content/objects">
A GET method that requires a template parameter.
</doc>
</method>
06/06/2013Presenter: Łukasz Serwatka Slide 15
APIGEE console & eZ Publish REST
Resources
 A single method can have a request definition with predefined data
<request>
<representation>
<!-- Set required to true to indicate the content as mandatory in
the Console -->
<apigee:payload required="true">
<!-- Body content. -->
<apigee:content>
<![CDATA[
]]>
</apigee:content>
</apigee:payload>
</representation>
</request>
06/06/2013Presenter: Łukasz Serwatka Slide 16
APIGEE console & eZ Publish REST
Parameters
 Methods can in turn have parameters. Parameters provide additional
granularity over interactions with resources. There are a number of different
ways of working with parameters in WADL.
 One benefit of using the Apigee Console is that it enables developers to
quickly understand which parameters are supported by the API, and how
developers can use parameters to accomplish specific tasks.
06/06/2013Presenter: Łukasz Serwatka Slide 17
APIGEE console & eZ Publish REST
Parameters
 Header parameter example:
<param name="Accept" required="true" type="xsd:string"
style="header"
default="application/vnd.ez.api.Content+json">
<doc>Response format.</doc>
<option value="application/vnd.ez.api.Content+json"
mediaType="application/json"/>
<option value="application/vnd.ez.api.Content+xml"
mediaType="application/xml"/>
</param>
06/06/2013Presenter: Łukasz Serwatka Slide 18
APIGEE console & eZ Publish REST
Parameters
 Template parameter example:
<resource path="/content/objects/{contentId}">
<param name="contentId" required="true" type="xsd:string"
style="template" default="57">
<doc>
eZ Publish Content ID
</doc>
</param>
</resource>
06/06/2013Presenter: Łukasz Serwatka Slide 19
APIGEE console & eZ Publish REST
Parameters
 Query parameter example:
<param name="param1" required="true" type="xsd:string"
style="query" default="12345">
<doc>Parameter description.</doc>
</param>
06/06/2013Presenter: Łukasz Serwatka Slide 20
APIGEE console & eZ Publish REST
Console To-Go

More Related Content

PPTX
Apigee deploy grunt plugin.1.0
Diego Zuluaga
 
PPTX
Building Creative Product Extensions with Experience Manager
Justin Edelson
 
PPTX
The Basics Angular JS
OrisysIndia
 
PDF
A gently introduction to AngularJS
Gregor Woiwode
 
PPT
Angular 8
Sunil OS
 
PPTX
Extend sdk
Harsha Nagaraj
 
PDF
Google Cloud Endpoints - Soft Uni 19.06.2014
Dimitar Danailov
 
PDF
Get rid of controllers in angular 1.5.x start using component directives
Marios Fakiolas
 
Apigee deploy grunt plugin.1.0
Diego Zuluaga
 
Building Creative Product Extensions with Experience Manager
Justin Edelson
 
The Basics Angular JS
OrisysIndia
 
A gently introduction to AngularJS
Gregor Woiwode
 
Angular 8
Sunil OS
 
Extend sdk
Harsha Nagaraj
 
Google Cloud Endpoints - Soft Uni 19.06.2014
Dimitar Danailov
 
Get rid of controllers in angular 1.5.x start using component directives
Marios Fakiolas
 

What's hot (20)

PPTX
Angular tutorial
Rohit Gupta
 
PDF
Building maintainable app #droidconzg
Kristijan Jurković
 
PDF
api-platform: the ultimate API platform
Stefan Adolf
 
PDF
RESTful services and OAUTH protocol in IoT
Yakov Fain
 
PDF
*Webinar* Learn from the Experts: How to Boost Test Coverage with Automated V...
Applitools
 
PDF
Integrating consumers IoT devices into Business Workflow
Yakov Fain
 
PDF
The Google App Engine Oil Framework
Eric ShangKuan
 
PDF
I Love APIs 2015: Continuous Integration the Virtuous Cycle
Apigee | Google Cloud
 
PDF
IPaste SDK v.1.0
xrebyc
 
PDF
JavaScript, React Native and Performance at react-europe 2016
Tadeu Zagallo
 
PPTX
Angular%201%20to%20angular%202
Ran Wahle
 
PDF
Flash Platformアップデート
Mariko Nishimura
 
ODP
Codegnitorppt
sreedath c g
 
PDF
AngularJS - dependency injection
Alexe Bogdan
 
PDF
Refactoring Large Web Applications with Backbone.js
Stacy London
 
PPTX
Angular modules in depth
Christoffer Noring
 
PPTX
Selendroid - Selenium for Android
Dominik Dary
 
PPTX
Sst hackathon express
Aeshan Wijetunge
 
PPTX
Mean stack Magics
Aishura Aishu
 
PDF
Andy Bosch - JavaServer Faces in the cloud
Andy Bosch
 
Angular tutorial
Rohit Gupta
 
Building maintainable app #droidconzg
Kristijan Jurković
 
api-platform: the ultimate API platform
Stefan Adolf
 
RESTful services and OAUTH protocol in IoT
Yakov Fain
 
*Webinar* Learn from the Experts: How to Boost Test Coverage with Automated V...
Applitools
 
Integrating consumers IoT devices into Business Workflow
Yakov Fain
 
The Google App Engine Oil Framework
Eric ShangKuan
 
I Love APIs 2015: Continuous Integration the Virtuous Cycle
Apigee | Google Cloud
 
IPaste SDK v.1.0
xrebyc
 
JavaScript, React Native and Performance at react-europe 2016
Tadeu Zagallo
 
Angular%201%20to%20angular%202
Ran Wahle
 
Flash Platformアップデート
Mariko Nishimura
 
Codegnitorppt
sreedath c g
 
AngularJS - dependency injection
Alexe Bogdan
 
Refactoring Large Web Applications with Backbone.js
Stacy London
 
Angular modules in depth
Christoffer Noring
 
Selendroid - Selenium for Android
Dominik Dary
 
Sst hackathon express
Aeshan Wijetunge
 
Mean stack Magics
Aishura Aishu
 
Andy Bosch - JavaServer Faces in the cloud
Andy Bosch
 
Ad

Similar to Apigee Console & eZ Publish REST (20)

PPTX
REST-API introduction for developers
Patrick Savalle
 
PDF
REST APIs
Arthur De Magalhaes
 
PPTX
A Deep Dive into RESTful API Design Part 2
VivekKrishna34
 
PDF
RESTful applications: The why and how by Maikel Mardjan
Jexia
 
PPTX
Building Valuable Restful APIs - HRPHP 2015
Guillermo A. Fisher
 
PDF
REST API Basics
Tharindu Weerasinghe
 
PPTX
IBM Integration Bus and REST APIs - Sanjay Nagchowdhury
Karen Broughton-Mabbitt
 
PPTX
Building a REST API for Longevity
MuleSoft
 
PPTX
REST Methodologies
jrodbx
 
PDF
Designing Web Apis Building Apis That Developers Love Jin Brendasahni
reknesluima
 
PPTX
Rest WebAPI with OData
Mahek Merchant
 
PDF
How to design a good rest api tools, techniques and best practices.
Nuwan Dias
 
PDF
How to design a good REST API: Tools, techniques and best practices
WSO2
 
PDF
the-10-rest-commandments.pdf
DavorKolenc1
 
PPTX
APIdays Paris 2014 - The State of Web API Languages
Restlet
 
PDF
Designing an API
Twobo Technologies
 
PPTX
Documenting an API for the First Time? Quick-Start Tips for Your First API Do...
Petko Mikhailov
 
PDF
Web API Design: Crafting Interfaces that Developers Love
Jamison K. Bell | OvenPOP 360
 
PDF
Web API Design
Jyotirmoy Dey
 
PPTX
Webservices: The RESTful Approach
Mushfekur Rahman
 
REST-API introduction for developers
Patrick Savalle
 
A Deep Dive into RESTful API Design Part 2
VivekKrishna34
 
RESTful applications: The why and how by Maikel Mardjan
Jexia
 
Building Valuable Restful APIs - HRPHP 2015
Guillermo A. Fisher
 
REST API Basics
Tharindu Weerasinghe
 
IBM Integration Bus and REST APIs - Sanjay Nagchowdhury
Karen Broughton-Mabbitt
 
Building a REST API for Longevity
MuleSoft
 
REST Methodologies
jrodbx
 
Designing Web Apis Building Apis That Developers Love Jin Brendasahni
reknesluima
 
Rest WebAPI with OData
Mahek Merchant
 
How to design a good rest api tools, techniques and best practices.
Nuwan Dias
 
How to design a good REST API: Tools, techniques and best practices
WSO2
 
the-10-rest-commandments.pdf
DavorKolenc1
 
APIdays Paris 2014 - The State of Web API Languages
Restlet
 
Designing an API
Twobo Technologies
 
Documenting an API for the First Time? Quick-Start Tips for Your First API Do...
Petko Mikhailov
 
Web API Design: Crafting Interfaces that Developers Love
Jamison K. Bell | OvenPOP 360
 
Web API Design
Jyotirmoy Dey
 
Webservices: The RESTful Approach
Mushfekur Rahman
 
Ad

Recently uploaded (20)

PPTX
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
PDF
NewMind AI Weekly Chronicles - July'25 - Week IV
NewMind AI
 
PPTX
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
PDF
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
PDF
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
PDF
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
PDF
The Future of Artificial Intelligence (AI)
Mukul
 
PDF
Software Development Methodologies in 2025
KodekX
 
PDF
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
PDF
Structs to JSON: How Go Powers REST APIs
Emily Achieng
 
PDF
Doc9.....................................
SofiaCollazos
 
PPTX
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
PDF
Oracle AI Vector Search- Getting Started and what's new in 2025- AIOUG Yatra ...
Sandesh Rao
 
PDF
OFFOFFBOX™ – A New Era for African Film | Startup Presentation
ambaicciwalkerbrian
 
PPTX
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
PDF
SparkLabs Primer on Artificial Intelligence 2025
SparkLabs Group
 
PDF
Automating ArcGIS Content Discovery with FME: A Real World Use Case
Safe Software
 
PPTX
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
PDF
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
PDF
Brief History of Internet - Early Days of Internet
sutharharshit158
 
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
NewMind AI Weekly Chronicles - July'25 - Week IV
NewMind AI
 
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
The Future of Artificial Intelligence (AI)
Mukul
 
Software Development Methodologies in 2025
KodekX
 
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
Structs to JSON: How Go Powers REST APIs
Emily Achieng
 
Doc9.....................................
SofiaCollazos
 
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
Oracle AI Vector Search- Getting Started and what's new in 2025- AIOUG Yatra ...
Sandesh Rao
 
OFFOFFBOX™ – A New Era for African Film | Startup Presentation
ambaicciwalkerbrian
 
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
SparkLabs Primer on Artificial Intelligence 2025
SparkLabs Group
 
Automating ArcGIS Content Discovery with FME: A Real World Use Case
Safe Software
 
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
Brief History of Internet - Early Days of Internet
sutharharshit158
 

Apigee Console & eZ Publish REST

  • 1. eZ Publish REST v2 calls made easy Apigee Console & eZ Publish REST
  • 2. 06/06/2013Presenter: Łukasz Serwatka Slide 2 APIGEE console & eZ Publish REST Presenter Łukasz Serwatka Product Management Technical Lead [email protected] @lserwatka  Working with eZ since 1st of March 2005  Over 10 years of experience with eZ Publish  Former member of the Engineering team, now in the Product Management  eZ Publish & Polish PHP Community Member  Expert in the mobile solutions (mobile applications & mobile strategies)
  • 3. 06/06/2013Presenter: Łukasz Serwatka Slide 3 APIGEE console & eZ Publish REST Console To-Go  The Apigee “eZ Publish” API console makes it easy to learn, test, and debug the eZ Publish REST v2 API with interactive tools and documentation.
  • 4. 06/06/2013Presenter: Łukasz Serwatka Slide 4 APIGEE console & eZ Publish REST API Providers
  • 5. 06/06/2013Presenter: Łukasz Serwatka Slide 5 APIGEE console & eZ Publish REST Console To-Go  Apigee Console To-Go describes the API using the Web Application Description Language (WADL). By uploading API description to Apigee a new custom Console can be created that allows to customize the look and feel, and then embed API Console on your own developer portal.  Console can display all methods available to developers, organized into the groups. Developers can browse the methods, reading the descriptions provided for each method and parameter, and see what information is required for each request, what authentication mechanisms are supported, and what parameters are optional or required. More importantly, developers can use the Console to enter authentication credentials and easily test requests and see what responses are returned.
  • 6. 06/06/2013Presenter: Łukasz Serwatka Slide 6 APIGEE console & eZ Publish REST Console To-Go: Name Your Console  Visit https://apigee.com/togo to setup a new console
  • 7. 06/06/2013Presenter: Łukasz Serwatka Slide 7 APIGEE console & eZ Publish REST Console To-Go: Set Credentials
  • 8. 06/06/2013Presenter: Łukasz Serwatka Slide 8 APIGEE console & eZ Publish REST Console To-Go: Describe Your API
  • 9. 06/06/2013Presenter: Łukasz Serwatka Slide 9 APIGEE console & eZ Publish REST What is WADL?  The Web Application Description Language (WADL) is an XML-based file format that provides a machine-readable description of HTTP-based web APIs. A WADL file defines the "resources" (that is, URIs) that constitute an API. For each resource, WADL defines one or more "methods" that act on those resources. With RESTful APIs, a 'method' is a combination of a resource (URI) and the HTTP verb (most commonly GET, PUT, POST and DELETE) that acts on the resource. WADL in its simplest form defines create, read, update and delete actions (sometimes referred to as CRUD operations) on resources defined by the API.
  • 10. 06/06/2013Presenter: Łukasz Serwatka Slide 10 APIGEE console & eZ Publish REST Resources  An example eZ Publish API that defines 3 resources: objects, locations, and sections.  http://api.example.com/api/ezp/v2/content/objects  http://api.example.com/api/ezp/v2/content/locations  http://api.example.com/api/ezp/v2/content/sections
  • 11. 06/06/2013Presenter: Łukasz Serwatka Slide 11 APIGEE console & eZ Publish REST Resources  Application definition <application xmlns:xsi="http://www.w3.org/2001/XMLSchema- instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:apigee="http://api.apigee.com/wadl/2010/07/" xmlns="http://wadl.dev.java.net/2009/02" xsi:schemaLocation="http://wadl.dev.java.net/2009/02 http://apigee.com/schemas/wadl-schema.xsd http://api.apigee.com/wadl/2010/07/ http://apigee.com/schemas/apigee-wadl-extensions.xsd"> <!-- Base defines the domain and base path of the endpoint -- > <resources base="http://api.demo.ez.no/api/ezp/v2"> </resources> </application>
  • 12. 06/06/2013Presenter: Łukasz Serwatka Slide 12 APIGEE console & eZ Publish REST Resources  Resource definition <application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:apigee="http://api.apigee.com/wadl/2010/07/" xmlns="http://wadl.dev.java.net/2009/02" xsi:schemaLocation="http://wadl.dev.java.net/2009/02 http://apigee.com/schemas/wadl-schema.xsd http://api.apigee.com/wadl/2010/07/ http://apigee.com/schemas/apigee- wadl-extensions.xsd"> <!-- Base defines the domain and base path of the endpoint --> <resources base="http://api.demo.ez.no/api/ezp/v2"> <!-- A resource with a GET method that requires a template parameter and a header --> <resource path="/content/objects/{contentId}"> </resource> </resources> </application>
  • 13. 06/06/2013Presenter: Łukasz Serwatka Slide 13 APIGEE console & eZ Publish REST Resources  For each resource, developers need a way to create, to read, to update, and to delete each resource--in other words, a set of methods is required for each resource. RESTful APIs usually define a:  POST method (for creating an article)  PUT method (for modifying an existing article)  GET method (for retrieving the article)  DELETE method (for removing articles)
  • 14. 06/06/2013Presenter: Łukasz Serwatka Slide 14 APIGEE console & eZ Publish REST Resources  A single GET method on the /content/objects resource. The method returns a list of content objects. <method id="get-content-objects" name="GET" apigee:displayName="content/objects"> <apigee:tags> <apigee:tag primary="true">Content Resources</apigee:tag> </apigee:tags> <apigee:authentication required="true"/> <apigee:example url="/content/objects"/> <doc apigee:url="http://api.mydomain.com/doc/content/objects"> A GET method that requires a template parameter. </doc> </method>
  • 15. 06/06/2013Presenter: Łukasz Serwatka Slide 15 APIGEE console & eZ Publish REST Resources  A single method can have a request definition with predefined data <request> <representation> <!-- Set required to true to indicate the content as mandatory in the Console --> <apigee:payload required="true"> <!-- Body content. --> <apigee:content> <![CDATA[ ]]> </apigee:content> </apigee:payload> </representation> </request>
  • 16. 06/06/2013Presenter: Łukasz Serwatka Slide 16 APIGEE console & eZ Publish REST Parameters  Methods can in turn have parameters. Parameters provide additional granularity over interactions with resources. There are a number of different ways of working with parameters in WADL.  One benefit of using the Apigee Console is that it enables developers to quickly understand which parameters are supported by the API, and how developers can use parameters to accomplish specific tasks.
  • 17. 06/06/2013Presenter: Łukasz Serwatka Slide 17 APIGEE console & eZ Publish REST Parameters  Header parameter example: <param name="Accept" required="true" type="xsd:string" style="header" default="application/vnd.ez.api.Content+json"> <doc>Response format.</doc> <option value="application/vnd.ez.api.Content+json" mediaType="application/json"/> <option value="application/vnd.ez.api.Content+xml" mediaType="application/xml"/> </param>
  • 18. 06/06/2013Presenter: Łukasz Serwatka Slide 18 APIGEE console & eZ Publish REST Parameters  Template parameter example: <resource path="/content/objects/{contentId}"> <param name="contentId" required="true" type="xsd:string" style="template" default="57"> <doc> eZ Publish Content ID </doc> </param> </resource>
  • 19. 06/06/2013Presenter: Łukasz Serwatka Slide 19 APIGEE console & eZ Publish REST Parameters  Query parameter example: <param name="param1" required="true" type="xsd:string" style="query" default="12345"> <doc>Parameter description.</doc> </param>
  • 20. 06/06/2013Presenter: Łukasz Serwatka Slide 20 APIGEE console & eZ Publish REST Console To-Go