GithubHelp home page GithubHelp logo

westlaw7x7 / vaporapp Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 37 KB

self-created Mock Server for Online_Shop project https://github.com/westlaw7x7/Online_Shop

Dockerfile 14.48% Swift 85.18% Procfile 0.34%

vaporapp's Introduction

VaporApp

Mock Server

https://online-shop-personal-a2a078cc9446.herokuapp.com/ - URL, deployed to HEROKU

/login

curl --location --request POST 'https://online-shop-personal-a2a078cc9446.herokuapp.com/login' \
--header 'Content-Type: application/json' \
--data-raw '{
"username" : "Somebody",
"password" : "mypassword"
}'

/logout

curl --location --request POST 'https://online-shop-personal-a2a078cc9446.herokuapp.com/logout' \
--header 'Content-Type: application/json' \
--data-raw '{"id_user" : 123}'

/register or /changeUserData

curl --location --request POST 'https://online-shop-personal-a2a078cc9446.herokuapp.com/register' \
--header 'Content-Type: application/json' \
--data-raw '{
"id_user" : 123,
"username" : "Somebody",
"password" : "mypassword",
"email" : "[email protected]",
"gender": "m",
"credit_card" : "9872389-2424-234224-234", 
"bio" : "This is good! I think I will switch to another language"
}'

curl --location --request POST 'https://gentle-depths-89634.herokuapp.com/changeUserData' \
--header 'Content-Type: application/json' \
--data-raw '{
"id_user" : 123,
"username" : "Somebody",
"password" : "mypassword",
"email" : "[email protected]",
"gender": "m",
"credit_card" : "9872389-2424-234224-234", 
"bio" : "This is good! I think I will switch to another language"
}'

/getProductsList Available categories String "m" - meal and String "d" - drink https://github.com/westlaw7x7/VaporApp/blob/master/Sources/App/Models/ProductsData.swift

curl --location --request POST 'https://online-shop-personal-a2a078cc9446.herokuapp.com/getProductList' \
--header 'Content-Type: application/json' \
--data-raw '{
"id_category": "m"
}'

/getSingleProduct Available data - https://github.com/westlaw7x7/VaporApp/blob/master/Sources/App/Models/ProductsData.swift

curl --location --request POST 'https://online-shop-personal-a2a078cc9446.herokuapp.com/getSingleProduct' \
--header 'Content-Type: application/json' \
--data-raw '{
"id_product": "m1"
}'

/addReview

curl --location --request PUT 'https://online-shop-personal-a2a078cc9446.herokuapp.com/addReview' \
--header 'Content-Type: application/json' \
--data-raw '{
    "review": "alalalalala",
    "nameOfReviewer": "John",
    "id": "m1"
}'

/deleteReview

curl --location --request PUT 'https://online-shop-personal-a2a078cc9446.herokuapp.com/deleteReview' \
--header 'Content-Type: application/json' \
--data-raw '{"id" : "m1"
}'

vaporapp's People

Contributors

alexander-grg avatar

Stargazers

 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.