tjlytle / api-example

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

API Design Training Example Project

Build a simple conference API as an exercise in API design.

Provided as a starting point:

  • The speaker / talk data.
  • A data service interface used to access the data.
  • A read-only implementation of the interface (should work).
  • A write implementation of the interface (not complete yet).

Docker

A simple docker-compose configuration provides a php development server, and a utility for running composer.

To run composer, use:

docker-compose run --rm composer [command]

composer dump-autoload should be used to setup autoloading for the data service.

To run the php development service:

docker-compose up php

By default, it expects the gateway script to be at public/index.php.

Data

To import the data, you can use conference_data/bin/import.php.

docker-compose run --rm php /app/conference_data/bin/import.php

About


Languages

Language:PHP 100.0%