Giter Club home page Giter Club logo

poketest's Introduction

Poké Test

Poke Test server/client. Server is ExpressJS/Typecript. Client is CRA bootstrapped using prop-types.

Getting Started

Checkout

  1. git pull https://github.com/gumacahin/poketest

Server

See API documentation below. To start do the server:

  1. cd server
  2. npm i
  3. npm run build
  4. npm run test
  5. npm run start

Start Client

  1. cd client
  2. npm i
  3. npm run start

API Documentation

API Server is an expressjs app. All endpoints except login requires an 'Authorization' header contaning the username of the current user.

API POST/PUT requires JSON in the req.body.

POST /login

Param: { username: <username> }

Creates a user with . Returning user object. If user does not exists it is created.

GET /shop

Resolves to items available in the shop.

GET /items

Resolves the current user's items

PUT /items

Param: {itemId: <item id of item being purchased>} Purchases an item for the current user. Resolves to error if funds are insufficient.

GET /pokemons

Resolves the current user's pokemons

PUT /pokemons

Param: {name: <item id of item being purchased>} Update current user's pokemon nickname. Resolves to pokemon object

GET /user

Resolves to current user.

poketest's People

Contributors

gumacahin 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.