Download the PHP package phonedotcom/mason-php without Composer

On this page you can find all versions of the php package phonedotcom/mason-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package mason-php

Mason PHP

Build Status Latest Stable Version Total Downloads Latest Unstable Version License

This project provides a PHP tool for building Hypermedia REST API's in Mason format.

At present, it includes a set of Mason Builder classes for producing data structures that can be passed to json_encode() for rendering Mason response bodies.

Example

Here is a simple example:

This produces the following data structure:

Motivation

Mason is a Hypermedia RESTful API format first published in 2013 by Jørn Wildt. It combines lessons learned from years of API implementations and close study of other competing formats such as Hal, Collection+JSON, and JSON-LD. Each format has its strengths, but none has the desired balance of simplicity and features.

Mason-PHP was built to help promote Mason adoption within the PHP community, and to provide much needed tooling.

Installation

This project is integrated with Composer. You can put it in your composer.json as a dependency:

Usage

Documentation is forthcoming. All public methods are documented inline, so at the moment, the best way to learn is to browse the code.

Tests

Run phpunit in the top folder. If you have the XDebug extension installed, you may also run it with the Code Coverage config which is provided separately, e.g. phpunit -c phpunit-coverage-html.xml

Contributors

This project was created and is managed by Phone.com. We're building a hot new Hypermedia API and we chose Mason!

Pull requests are welcome.

License

This project is released under the MIT License. Copyright (c) 2015 Phone.com, Inc. See LICENSE for full details.


All versions of mason-php with dependencies

PHP Build Version
Package Version
Requires php Version >=5.5
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package phonedotcom/mason-php contains the following files

Loading the files please wait ....