Skip to content

Latest commit

 

History

History
47 lines (34 loc) · 988 Bytes

README.md

File metadata and controls

47 lines (34 loc) · 988 Bytes

Gogoprint PHP Developer Test

Requirements

Installation

  1. Clone project git clone https://github.com/Seb33300/Gogoprint-PHP-Developer-Test.git
  2. Install PHP dependencies composer install
  3. Launch web server php bin/console server:start

A ready-to-use SQLite database is included in the project. (only the first product configuration options have been set => with id 1)

How to use

Use the REST client of your choice to make requests. Using a web browser may not works!

Get Form Options

GET http://127.0.0.1:8000/api/product/options

Get Price Table

GET http://127.0.0.1:8000/api/product/prices?paper_format_id=1&pages_id=1&paper_type_id=1

Add To Cart

POST http://127.0.0.1:8000/api/product/cart
{
    "paper_format_id": "1",
    "pages_id": "1",
    "paper_type_id": "1",
    "quantity": "100",
    "date": "2019-02-26"
}