PHPackages                             nilportugues/jsonapi-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. nilportugues/jsonapi-bundle

ActiveLibrary[API Development](/categories/api)

nilportugues/jsonapi-bundle
===========================

Symfony 2 &amp; 3 JSON API Transformer Package

2.1.0(8y ago)11446.0k↓50%17[12 issues](https://github.com/nilportugues/symfony-jsonapi/issues)[1 PRs](https://github.com/nilportugues/symfony-jsonapi/pulls)MITPHPPHP &gt;=5.5.0

Since Aug 23Pushed 6y ago11 watchersCompare

[ Source](https://github.com/nilportugues/symfony-jsonapi)[ Packagist](https://packagist.org/packages/nilportugues/jsonapi-bundle)[ Docs](http://nilportugues.com)[ RSS](/packages/nilportugues-jsonapi-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (4)Versions (21)Used By (0)

Symfony JSON-API Transformer Bundle
===================================

[](#symfony-json-api-transformer-bundle)

For Symfony 2 and Symfony 3

[![Scrutinizer Code Quality](https://camo.githubusercontent.com/519c742baeb772eca6ec62668ac29923334ad6940d6da8bce566856f425e938d/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f6e696c706f727475677565732f73796d666f6e79322d6a736f6e6170692d7472616e73666f726d65722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/nilportugues/symfony2-jsonapi-transformer/?branch=master)[![SensioLabsInsight](https://camo.githubusercontent.com/67c962e53077787dd6ea5a14b5d4e67e3e10d7d995141c62936deacfb603fcff/68747470733a2f2f696e73696768742e73656e73696f6c6162732e636f6d2f70726f6a656374732f33323639663132652d613730372d343632612d626566352d3232653565643532326538652f6d696e692e706e673f)](https://insight.sensiolabs.com/projects/3269f12e-a707-462a-bef5-22e5ed522e8e)[![Latest Stable Version](https://camo.githubusercontent.com/2bbc01729ca7b36bbfb5eb04c90d60a2f954c23b2bb27fbaa12f1b6e8d250caf/68747470733a2f2f706f7365722e707567782e6f72672f6e696c706f727475677565732f6a736f6e6170692d62756e646c652f762f737461626c65)](https://packagist.org/packages/nilportugues/jsonapi-bundle)[![Total Downloads](https://camo.githubusercontent.com/25bb1ba2e3fac4113bc17c56d69fe4313d95096b544d90baa5d1a7149e58f94c/68747470733a2f2f706f7365722e707567782e6f72672f6e696c706f727475677565732f6a736f6e6170692d62756e646c652f646f776e6c6f616473)](https://packagist.org/packages/nilportugues/jsonapi-bundle)[![License](https://camo.githubusercontent.com/5c72d38172223ce1cc94933e872036fc7a78b8afbbbfea24bcb4b636ea829700/68747470733a2f2f706f7365722e707567782e6f72672f6e696c706f727475677565732f6a736f6e6170692d62756e646c652f6c6963656e7365)](https://packagist.org/packages/nilportugues/jsonapi-bundle)[![Donate](https://camo.githubusercontent.com/7b6de155df30b37b25eb5fec52f9213680c3dbf067dfb7d7e2850ac4096c7d05/68747470733a2f2f7777772e70617970616c6f626a656374732e636f6d2f656e5f55532f692f62746e2f62746e5f646f6e6174655f534d2e676966)](https://paypal.me/nilportugues)

- [Installation](#installation)
- [Usage](#usage)
    - [Creating the mappings](#creating-the-mappings)
- [Outputing API Responses](#outputing-api-responses)
    - [JSON API Requests](#request-objects)
    - [JSON API Responses](#response-objects-jsonapiresponsetrait)
- [Integration with NelmioApiDocBundleBundle](#integration-with-nelmioapidocbundlebundle)
- [Quality](#quality)
- [Contribute](#contribute)
- [Support](#support)
- [Authors](#authors)
- [License](#license)

Installation
------------

[](#installation)

**Step 1: Download the Bundle**

Open a command console, enter your project directory and execute the following command to download the latest stable version of this bundle:

```
$ composer require nilportugues/jsonapi-bundle
```

**Step 2: Enable the Bundle**

Then, enable the bundle by adding it to the list of registered bundles in the `app/AppKernel.php` file of your project:

```
