-
Notifications
You must be signed in to change notification settings - Fork 0
Model structure
kenn edited this page Sep 14, 2010
·
1 revision
{ "id":1,
"name":"double jumper",
"description":"get this by jump twice",
"value":100,
"icon_url":"http://localhost:3000/images/s48/missing.png",
"is_secret":false }
{ "achievement_point":300,
"achievement_total":5300 }
{ "udid":"0123456789abcdef",
"name":"Foo's iPhone 3GS",
"os":"3.1.3",
"hardware":"iPhone2,1" }
{ "id":2,
"name":"hotgame",
"description":null,
"grade_enabled":true,
"icon_url":"http://localhost:3000/images/s48/missing.png" }
{ "id":1,
"name":"soldier",
"point":0 }
{ "grade_point":10,
"grade":(grade) }
{ "achievement_status":(achievement_status) }
grade_enabled=trueなゲームの場合の付加情報
{"grade_status":(grade_status)}
with_gameが指定された場合の付加情報
{"game":(game)}
include=achievementsを指定した場合の付加情報
{"achievements":[(achievement), (achievement), ... ]}
{ "id":1,
"name":"Grade",
"type":"grade",
"sort_by":"latest_delta",
"score_base":0,
"min_version":null,
"max_version":null }
{ "id":7,
"room_id":"Tnd2OR",
"users":[(user(with_install)), (user(with_install)), ... ],
"start_at":"2010-03-03T16:25:28Z",
"end_at":null }
{ "id":"Hxoc3j",
"user":(user(with_install)),
"ip":"127.0.0.1",
"nat":"NO_NAT" }
natの値に入るのは SYMMETRIC, PORT_RESTRICTED_CONE, RESTRICTED_CONE, FULL_CONE, NO_NAT, UNKNOWN のいずれか。
{ "leaderboard":(leaderboard),
"value":"3",
"total":3,
"score":(score) }
{ "id":1,
"type":"follow",
"from":(user),
"to":(user) }
{ "id":"2j4XbE",
"name":"kenn's room 001",
"is_public":true,
"max_members":5,
"is_pairing_requested":false,
"memberships":[(membership), (membership), ... ] }
gradeがセットされたルームの場合の付加情報
{ "grade_limit":
{ "id":1,
"range":"eq" } }
{ "value":700,
"user":(user(with_install)) }
{ "id":"1fphNy",
"public_id":"Hxoc3j",
"user":(user(with_install, owner)),
"game":(game) }
public_idは、roomに参加するときのmembership構造体のidに同じ
{ "id":106538432,
"screen_name":"pankakudev" }
{ "id":6,
"username":"kenn",
"country":"--",
"icon_url":"http://localhost:3000/images/twitter/default.png" }
ownerの場合の付加情報(サーバ内部仕様)
{ "is_guest":false,
"is_secured":true }
include=twitterを指定した場合の付加情報
{"twitter":(twitter)}
is_following=(user)が指定された場合の付加情報(サーバ内部仕様)
{"is_following":true}
relationships_with=(user)が指定された場合の付加情報(サーバ内部仕様)
{"relationships":[(relationship), (relationship), ... ]}
with_installが指定された場合の付加情報(サーバ内部仕様)
{"install":(install)}
include=installsを指定した場合の付加情報
{"installs":[(install(with_game)), (install(with_game)), ... ]}