Giter VIP home page Giter VIP logo

fut14's Introduction

fut14

https://travis-ci.org/oczkers/fut14.png?branch=master

fut14 is a simple library for managing Fifa 14 Ultimate Team. It is written entirely in Python.

Documentation

Documentation is available at http://fut14.readthedocs.org/.

Players database: http://cdn.content.easports.com/fifa/fltOnlineAssets/C74DDF38-0B11-49b0-B199-2E2A11D1CC13/2014/fut/items/web/players.json

Usage

>>> import fut14
>>> fut = fut14.Core('email', 'password', 'secret answer', platform='xbox', debug=True)
>>> # PLATFORM: pc / ps3 / xbox / and / ios     (pc default)
>>> # DEBUG: save http response to fut14.log)

>>> items = fut.searchAuctions('development',  # search items
...     level='gold', category='fitness', min_price=300,  # optional parametrs
...     max_price=600, min_buy=300, max_buy=400,  # optional parametrs
...     start=0, page_size=50)  # optional parametrs

>>> for item in items:
...     trade_id = item['tradeId']
...     buy_now_price = item['buyNowPrice']
...     trade_state = item['tradeState']
...     bid_state = item['bidState']
...     starting_bid = i['startingBid']
...     item_id = i['id']
...     timestamp = i['timestamp']  # auction start
...     rating = i['rating']
...     asset_id = i['assetId']
...     resource_id = i['resourceId']
...     item_state = i['itemState']
...     rareflag = i['rareflag']
...     formation = i['formation']
...     injury_type = i['injuryType']
...     suspension = i['suspension']
...     contract = i['contract']
...     playStyle = i['playStyle']  # used only for players
...     discardValue = i['discardValue']
...     itemType = i['itemType']
...     owners = i['owners']
...     offers = i['offers']
...     current_bid = i['currentBid']
...     expires = i['expires']  # seconds left

>>> fut.credits  # returns credits amount
600

>>> fut.bid(items[0]['trade_id'], 600)  # make a bid

>>> fut.credits  # it's updated automatically on every request
0
>>> fut.tradepile_size  # tradepile size (slots)
80
>> len(fut.tradepile())  # tradepile fulfilment (number of cards in tradepile)
20
>>> fut.watchlist_size  # watchlist size (slots)
30
>> len(fut.watchlist())  # watchlist fulfilment (number of cards in watchlist)
10

>>> items = fut.tradepile()  # get all items from trade pile
>>> items = fut.unassigned()  # get all unassigned items

>>> for item in items:
...     fut.sell(item['item_id'], 150,  # put item on auction
...              buy_now=0, duration=3600)  # optional parametrs

>>> fut.sendToTradepile(trade_id, item_id)  # add card to tradepile
>>> fut.sendToClub(trade_id, item_id)       # add card to club
>>> fut.sendToWatchlist(trade_id)           # add card to watchlist
>>> fut.tradepileDelete(trade_id)           # removes item from tradepile
>>> fut.watchlistDelete(trade_id)           # removes item from watch list
>>> fut.quickSell(item_id)                  # quicksell item

>>> fut.relist()  # relist all expired cards in tradepile

>>> fut.keepalive()  # send keepalive ping to avoid timeout (send at least one request every ~10 minutes)

to be continued ;-)
...

CLI examples

not yet
...

License

GNU GPLv3

fut14's People

Contributors

oczkers avatar mvillarejo avatar renatonasc avatar sheh 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.