Skip to content

Server API URLs

Ali Shirmohammadi edited this page Jul 6, 2019 · 14 revisions

Authentication functions:

URL required parameters optional parameters success response data
/login username, password logged in user
/sign_up username, password signed up user
/profile token logged in user

Shop functions:

URL required parameters optional parameters success response data
/shop/search token search, type list of cards as a HashMap
/shop/buy token, card_name logged in user after buying card
/shop/sell token, card_name logged in user after selling card

Collection functions:

URL required parameters optional parameters success response data
/collection/search token search, type list of cards as set
/collection/create_deck token, name search, type created deck
/collection/add_card_to_deck token, deck_name, card_name deck after adding card
/collection/get_deck token, deck_name requested deck
/collection/remove_deck token, deck_name, card_name logged in user
/collection/remove_card_from_deck token, deck_name, card_name deck after removing card
/collection/is_valid token, deck_name true or false
/collection/set_main_deck token, deck_name main deck after setting
  • All of api functions must be called with GET method.
  • The result of api functions is a "Response" Object.
  • All of api functions except login and sign_up need token for user authentication.
Clone this wiki locally