Coder Social home page Coder Social logo

party-tonight-backend's Introduction

Party-Tonight-Backend

SignUp

Maker

uri: /partymaker/maker/signup

method: POST

type: application/json

body: {

"userName":"John",
"phoneNumber":"066565",
"email":"email.com",
"emergencyContact":"contact",
"password":123,
"billing":{
	"card_number":"1234"
}

}

Dancer

uri: /partymaker/dancer/signup

method: POST

type: application/json

body: {

"userName":"M",
"phoneNumber":"066565",
"email":"m.com",
"emergencyContact":"contact",
"password":123

}

SignIn:

uri: /signin

method: GET

type: application/json

header: Authorization = Basic bS5jb206MTIz

Create id_event

uri: /partymaker/maker/id_event/create

method: POST

type: application/json

header: x-auth-token = signInMakerToken

body:

{

"club_name": "NewEvent",
"date": "cannot be null",
"location": "cannot be null",
"club_capacity": "cannot be null",
"party_name": "id_event",
"zip_code": "231",

"bottles": [
  {
    "name": "champain",
    "price": "2",
    "type": "type",
    "available": "1000",
    "booked": "10"
  }
],
"tickets": [
  {
    "price": "12",
    "available": "100",
    "booked": "2",
    "created_date": null
  }
],
"tables": [
  {
    "price": "3",
    "type": "type",
    "available": "100",
    "booked": "10"
  }
],
"photos": [
  {
    "photo": "photo"
  }
]

}

Get id_event(for maker)

uri: /partymaker/maker/id_event/get

method: GET

type: application/json

header: x-auth-token = signInMakerToken

response: array(list) of events

Get id_event(for dancer)

uri: /partymaker/dancer/id_event/get

method: GET

type: application/json

header: x-auth-token = signInDancerToken

header: zip_code = zipCodeEvent

response: array(list) of events

Revenue (tickets booked * ticket_price)

uri: /maker/id_event/revenue

method: GET

type: --//--

header: x-auth-token = signInMakerToken

header: party_name = party_name

response:

{ "revenue": "516.0" }

Bottles

uri: /maker/id_event/bottles

method: GET

type: --//--

header: x-auth-token = signInMakerToken

header: party_name = party_name

response:

[ { "id_bottle": 1, "name": "champain", "price": "2", "type": "type", "available": "1000", "booked": "10", "createdDate": null } ]

Tables

uri: /maker/id_event/tables

method: GET

type: --//--

header: x-auth-token = signInMakerToken

header: party_name = party_name

response:

[ { "id_table": 1, "price": "3", "type": "type", "available": "100", "booked": "10" } ]

Total

uri: /maker/id_event/total

method: GET

type: --//--

header: x-auth-token = signInMakerToken

header: party_name = party_name

response:

{ "withdrawn": "1200.0", "ticketsSales": "24.0", "bottleSales": "20.0", "tableSales": "30.0", "refunds": "-1126.0" }

party-tonight-backend's People

Contributors

enemym avatar therealgetman avatar

Watchers

James Cloos avatar  avatar  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.