Giter Site home page Giter Site logo

api-poc's Introduction

API PoC

Requires PHP 7.4

Install dependencies

composer install

Create database (sqlite) and update schema

php bin/console doctrine:database:create
php bin/console doctrine:schema:update --force

Load fixtures

php bin/console hautelook:fixtures:load

(Install symfony binary for Symfony server https://symfony.com/doc/current/setup/symfony_server.html#installation)

Start server

symfony server:start

list() action features

Use API token sk_user_1 and try /customers endpoint (base URL is http://127.0.0.1:8000 when running symfony server:start).

Use pageSize, page, orderBy, filters, search and fields parameters.

http://127.0.0.1:8000/customers
http://127.0.0.1:8000/customers?pageSize=1&page=2
http://127.0.0.1:8000/customers?orderBy=id DESC
http://127.0.0.1:8000/customers?filters=name:like:Example
http://127.0.0.1:8000/customers?search=Bar
http://127.0.0.1:8000/customers?fields=id,name

Endpoint ideas

GET /tasks                  # Returns company's all tasks
GET /teams/{id}/tasks       # Returns all tasks belonging to team {id}
GET /teams/all/tasks        # Returns all tasks belonging to any user's teams

GET /teams/all/tasks?filters=group:eq:123,456

api-poc's People

Contributors

attemanninen avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.