2017 © Pedro Peláez
 

library jcdecauxcyclocity-bundle

this bundle provides easy integration of the Cyclocity OpenData Rest API provided by JCDecaux

image

killerwolf/jcdecauxcyclocity-bundle

this bundle provides easy integration of the Cyclocity OpenData Rest API provided by JCDecaux

  • Tuesday, October 14, 2014
  • by killerwolf
  • Repository
  • 1 Watchers
  • 1 Stars
  • 15 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

JCDecauxCyclocityBundle

Scrutinizer Code Quality SensioLabsInsight Dependency Status, (*1)

This is a simple bundle to use the JCDecaux Cyclocity OpenData Rest API in a Symfony2 project, (*2)

Install

Install with composer and enable the bundle in the kernel., (*3)

Usage

First, Add your API KEY (from jcdecaux developers portal) in app/conf/config.yml, (*4)

killerwolf_jc_decaux_cyclocity:
    api_key: "YOU_API_KEY"

Finaly use the service into your controller,, (*5)

<?php

namespace Killerwolf\JCDecauxCyclocityBundle\Controller;

use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Symfony\Component\HttpFoundation\Request;

class DefaultController extends Controller
{
    public function indexAction(Request $request)
    {
        $api = $this->get('cyclocity.data');

        return $this->render(
            'KillerwolfJCDecauxCyclocityBundle:Default:index.html.twig', 
            [
                'stations' => $api->getStationsByContract( 'Paris' )
            ]
        );
    }
}

The Versions

14/10 2014

dev-master

9999999-dev

this bundle provides easy integration of the Cyclocity OpenData Rest API provided by JCDecaux

  Sources   Download

MIT

The Requires

 

12/10 2014

0.1.0

0.1.0.0

this bundle provides easy integration of the Cyclocity OpenData Rest API provided by JCDecaux

  Sources   Download

MIT

The Requires