Skip to content

shrredd/nba-wins-pool

master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
api
 
 
 
 
 
 
 
 
 
 
 
 

NBA Wins Pool

Back in 2012, Bill Simmons came up with the idea for an NFL Wins Pool. Check out Bill's article for the basic idea. My friend John and I wanted to make this happen for the NBA. John made an iPhone app. This repository is the draft order logic that it pulls from.

Wins Pool Leaderboard

Rough API

/user/create
  Params:
    -> name (String)
  Returns:
    -> user_id (String)

/pool/size
  Returns:
    -> json.write('2', '3', '5', '6')

/pool/create
  Params:
    -> creator_id (Int)
    -> pool_size (Int)
    -> pool_name (String)
  Returns:
    -> pool_id (String)

/pool/status
  Returns:
    -> pool_status (Dict):
      {
        1 :
        [
          user: {id: "abc12324", name: "Jason Smith"},
          team (None if not drafted yet): {id: "atlanta-hawks", name: "Atlanta Hawks"} or None)
         ],
        2 :
        [
          user: {id: "xasarf3212", name: "Eric Smith"},
          team (None if not drafted yet): {id: "boston-celtics", name: "Boston Celtics"} or None)
         ]
         ...
      }

/pool/join
  Params:
    -> user_id (String)
    -> pool_id (String)
  Returns:
    -> success (Bool)

/pool/select
  Params:
    -> user_id (String)
    -> team_id (String)
  Returns:
    -> pool_status (Dict):
      {
        1 :
        [
          user: {id: "abc12324", name: "Jason Smith"},
          team (None if not drafted yet): {id: "atlanta-hawks", name: "Atlanta Hawks"} or None)
         ],
        2 :
        [
          user: {id: "xasarf3212", name: "Eric Smith"},
          team (None if not drafted yet): {id: "boston-celtics", name: "Boston Celtics"} or None)
         ]
         ...
      }

About

A Wins Pool App for the NBA

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages