2017 © Pedro Peláez
 

library response-json-envelope

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

image

sarelvdwalt/response-json-envelope

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

  • Monday, November 2, 2015
  • by sarelvdwalt
  • Repository
  • 1 Watchers
  • 0 Stars
  • 6 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 3 Forks
  • 1 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

ResponseJSONEnvelope

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code., (*1)

Installation

composer require sarelvdwalt/response-json-envelope

Usage

It is intended to be used inside a Symfony 2+ standard install., (*2)

Inside one of your controllers, use it like this:, (*3)

When returning a success:, (*4)

return new ResponseJSON($payloadObject, Response::HTTP_OK);

When returning a failure (example the object is not found):, (*5)

return new ResponseJSON(null, Response::HTTP_NOT_FOUND, null);

The Versions

02/11 2015

dev-master

9999999-dev

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

  Sources   Download

MIT

The Requires

 

The Development Requires

by Sarel van der Walt

02/11 2015

0.1.3

0.1.3.0

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

  Sources   Download

MIT

The Requires

 

The Development Requires

by Sarel van der Walt

08/10 2015

0.1.2

0.1.2.0

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

  Sources   Download

MIT

The Requires

 

The Development Requires

by Sarel van der Walt

07/10 2015

dev-develop

dev-develop

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

  Sources   Download

MIT

The Requires

 

The Development Requires

by Sarel van der Walt

07/10 2015

0.1.1

0.1.1.0

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

  Sources   Download

MIT

The Requires

 

The Development Requires

by Sarel van der Walt

07/10 2015

0.1.0

0.1.0.0

A simple object that can be used to put a response (in JSON, given as an array) inside a standard envelope, giving you a place to put certain meta-data, including the response-code.

  Sources   Download

MIT

The Requires

 

by Sarel van der Walt