Skip to content

valentinpx/pixels_backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pixels

Réalisé lors d'une Jam sur le thème du street art.

Les utilisateurs peuvent ajouter des pixels grace à des coordonées et une couleur. preview/pixel.png preview

Les pixels créés apparaissent sur le mur. preview/wall.png preview

Ce repo contient le backend, du projet. Le frontend est disponible sur le profil de Lucas Decrock

API

List all pixels color by id

Definition

  • GET /api/pixels

Response

  • 200 OK on success
[
    {
        "color" : "FFFFFF",
        "id" : "1"
    },
    {
        "color" : "000000",
        "id" : "103680"
    }
]

Get a specified pixel

Definition

  • GET /api/pixels/<id>

Response

  • 200 OK on success
{
    "color" : "000000",
    "id" : 10
}
  • 404 Not Found if "Q" does not exist

Modify a pixel color

Definition

  • POST /api/pixels/<id>/edit

Arguments

  • "color":string hexadecimal color without any '#'

Response

  • 200 OK on success
  • 404 Not Found if pixel does not exist
  • 401 Invalid Color if color is not hexadecimal with 6 characters

Surprise

Definition

  • GET /api

Response This is endpoint is usefull to check wether if the api works, the response is a surprise 👀

Inspired by r/places.

About

Epitech Jam about street art

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published