Skip to the content
Documentation

apiapi

REST API Authentication (page id 31430293) The REST API supports two authentication methods: session, and basic. Getting started with the REST API (page id 31430289) No special preparations are necessary to use the REST API. As long as your eZ Platform is correctly configured, the REST API is available on your site using the URI /api/ezp/v2/. If you have installed eZ Platform in a subfolder, prepend the path with this subfolder: http://example.com/sub/folder/exp REST API reference (page id 31430594) The complete reference (specification) of the REST API resources is found bundled with your software, or online: Settings schema and allowed validators (page id 31430771) FieldType->$settingsSchema and FieldType->$allowedValidators are intentionally left free-form, to give broadest freedom to Field Type developers. However, for internal Field Types (aka those delivered with eZ Platform), a common standard should be established as best practice. The purpose of this pa Field Type template (page id 31430773) In order to be used by ez_render_field() Twig helper, you need to define a template containing a block dedicated to the Field display. Error handling (page id 31430302) Error handling in the REST API is fully based on HTTP error codes. As a web developer, you are probably familiar with the most common ones: 401 Unauthorized, 404 Not Found or 500 Internal Server Error. The REST API uses those, along with a few more, to allow proper error handling. eZ Platform Public PHP API The PHP API is also commonly referred to as the "Public API". Currently it exposes a Repository which allows you to create, read, update, manage and delete all objects available in eZ Platform, first and foremost content, but also related objects like Sections, Locations, Content Types, Content Type Error handling Error handling in the REST API is fully based on HTTP error codes. As a web developer, you are probably familiar with the most common ones: 401 Unauthorized, 404 Not Found or 500 Internal Server Error. The REST API uses those, along with a few more, to allow proper error handling. Field Type template In order to be used by ez_render_field() Twig helper, you need to define a template containing a block dedicated to the Field display. General REST usage As explained in the introduction, the REST API is based on a very limited list of general principles: