NAV Navbar
protocol python csharp
  • Private API Introduction
  • Private API Calls
  • Data Types
  • Public API Introduction
  • Public API Calls
  • API Libraries & Source Code
  • Private API Introduction

    The Fairlay Private API allows you to POST requests (creating/changing markets and orders, transfering funds, etc.), costs 0.1mBTC per 100.000 requests, see below on how to create your developer API account.

    This is the low level documentation, if you need a working sample or are more comfortable reading code rather than specifications, head over to .NET API Library or Python API Library

    Requisites

    1. An account registered at fairlay
    2. A 2048 bits PEM RSA Key pair. There are multiple types of tools to generate it for you. Tools SSL Example
    3. Create an API account in profile page at https://fairlay.com/developer/api/new/. Will be requested to provide your public key on form.

    Requests

    All requests should be made to this endpoint:

    31.172.83.53:18017

    You must sign messages with your RSA key and provide your signature with all requests:

    nonce|userID|requestID|requestData

    The signature shoud be digested RSA-SHA512 signature encoded in Base64.

    This is a sample GETBALANCE Request using default ACCOUNT ID 1:

    uiskPc9GqWAdUt1hJ+4VeuxyCNtbs0iY3kSbGQZ7HvwHkCe5H2n9UcX5v1Gl7Mb99XnhBiVzkne5bdkgmLdnlzzEBPLYnt8zwWHcqxXvIYiDpLQhsVfdkvyYwH1zgrUwAZu08VmY0ax34zxjXJdK68TVs9Y1m7akXkw5/NvIwXk=|635972931146604657|100012|1022|<ENDOFDATA>
    

    The response is usually JSON-encoded:

    rfV2ylPLbDbBKEy0yi71xZS/fZbyozd7+smpit1cR8ZeB0qo+stRDttTkCxqF0towkS0bf3lkg4amSbvka6K//QX/F1BHdFNqpkFXQHB9jh2eyR2WgXblKeGRbgw+mma+1P/kKNBtf3qhOUiqOgzONwlTEusiLzqHil6HLTQTKY=|635972681796848020|1066|{"PrivReservedFunds":334.049,"MaxFunds":0.0,"PrivUsedFunds":207.12,"AvailableFunds":126.946}
    

    If there is an error, the server returns an error message starting with XError: for general errors or YError: if there was an error in a subtask of a bulk change order request.

    Requests must be send via TCP in the following format:

    signature|nonce|userid|requestID|requestData<ENDOFDATA>

    Every request must end with <ENDOFDATA>

    Remember to use (YOUR API ID*1000)+Request ID on requests. Example: If you create your API accont on Fairlay, site will set an ID to it, usually first API ID is 1. So a request to Get Orderbook with this account will be 1001.

    Private API Calls

    Get Public Key (GETPUBLICKEY)

    signature|nonce|id|GETPUBLICKEY
    

    Response: returns the server's public key in XML format.

    Get Server Time (2)

    signature|nonce|userid|1002
    

    Response: returns the server's time in ticks.

    636451764120705300

    Note: the server time can also be interfered from the nonce in every response.

    Get Me (21)

    signature|nonce|userid|1021
    

    Returns: User info object containing last connections, withdraw adresses, market makers, funds, API Accounts, screen name and ID.

    Get My Balance (22)

    signature|nonce|userid|1022
    

    Returns: JSON object containing account balance information:

    PrivReservedFunds: Total account funds in mBTC. PrivUsedFunds: Amount of balance placed on opened markets in mBTC. AvailableFunds: Amount of balance available to use in mBTC. SettleUsed: Amount retained due to settlement in mBTC. CreatorUsed: Amount retained by market creation in mBTC. RemainingRequests: Requests remaining before new charge.

    Set API Account to Readonly (49)

    signature|nonce|userid|1049|
    

    This will permanently set your API Account #5 to Read Only. This cannot be undone.

    You can also set your API Account #0 to read only. But be careful with it:

    signature|nonce|userid|49|
    

    Get Orderbook (1)

    signature|nonce|userid|1001|marketID
    

    Response: An array containing one object with orderbooks for each runner in market.

    [{ "Bids": [ [3.954, 3.75] ], "Asks": [ [7.203, 2.06156] ], "S": 1 }, { "Bids": [ [5.627,2.63] ], "Asks": [], "S": 1}]

    This is a return from a market with 2 runners.

    Get Orderbooks (4)

    signature|nonce|userid|4|[marketID1, marketID2]
    signature|nonce|userid|4|[121046999588, 121046400020]
    

    Response: An array of objects containing orderbooks for each runner in market.

    [{ "Bids": [ [3.954, 3.75] ], "Asks": [ [7.203, 2.06156] ], "S": 1 }, { "Bids": [ [5.627,2.63] ], "Asks": [], "S": 1},{ "Bids": [ [3.954, 3.75] ], "Asks": [ [7.203, 2.06156] ], "S": 1 }, { "Bids": [ [5.627,2.63] ], "Asks": [], "S": 1}]

    This is a return from 2 markets with 2 runners.

    Get Market (6)

    signature|nonce|userid|1006|marketid
    

    Returns: market object

    Get Markets (7)

    signature|nonce|userid|1007|{
    "Cat":0,
    "RunnerAND":["Arsenal","Chelsea"],
    "TitleAND":null,
    "TitleNOT":["Corners","Throwin"],
    "Comp":"Premier Leag",
    "TypeOR":null,
    "PeriodOR":[1],
    "SettleOR":null,
    "ToSettle":false,
    "OnlyMyCreatedMarkets":false,
    "Descr":null,
    "ChangedAfter":"2016-01-01T22:01:01",
    "SoftChangedAfter":"0001-01-01T00:00:00",
    "OnlyActive":false,
    "MinPop":0.0,
    "MaxMargin":103.0,
    "NoZombie":false,
    "FromClosT":"2016-05-01T00:00:00",
    "ToClosT":"0001-01-01T00:00:00",
    "FromID":0,
    "ToID":100,
    "SortPopular":false}
    

    Returns all markets that apply to the given filter.

    Cat: is the Category, 0 queries all Categories.

    RunnerAND: All strings provided must be contained in the names of the runners of the market.

    TitleNOT: None of the strings may appear in the title of the market

    TypeOr: Only the Market Types given will be returned. If set to null, all market types will be returned. See A2) for Market Types

    PeriodOr: Similiar to TypeOr See A2) for Market Periods

    SettleOr: See A2) for Settlement Types

    ToSettle: If set to true, it will only return unsettled markets where the resolution time has passed.

    NoZombie: No empty markets (without any open order)

    Descr: The given string must appear in the market description.

    ChangedAfter: Only returns markets, where the meta data was changed after the given date. Usually the Closing and Settlement Dates of a market is the only data that changes. SoftChangedAfter: Returns all markets, where either the the meta data or the orderbook has changed since the given date.

    Returns: a list of market objects

    Get Markets Orderbook (67)

    signature|nonce|userid|1067|{
    "Cat":0,
    "RunnerAND":["Arsenal","Chelsea"],
    "TitleAND":null,
    "TitleNOT":["Corners","Throwin"],
    "Comp":"Premier Leag",
    "TypeOR":null,
    "PeriodOR":[1],
    "SettleOR":null,
    "ToSettle":false,
    "OnlyMyCreatedMarkets":false,
    "Descr":null,
    "ChangedAfter":"2016-01-01T22:01:01",
    "SoftChangedAfter":"0001-01-01T00:00:00",
    "OnlyActive":false,
    "MinPop":0.0,
    "MaxMargin":103.0,
    "NoZombie":false,
    "FromClosT":"2016-05-01T00:00:00",
    "ToClosT":"0001-01-01T00:00:00",
    "FromID":0,
    "ToID":100,
    "SortPopular":false}signa
    

    Returns: A long-string Dictionary with the marketID - orderbook key-value pair.

    Create Market (11)

    signature|nonce|userid|1011|{
    "Comp":"Politics",
    "Descr":"This market resolves to Yes, if the Senate confirms Merrick Garland’s Supreme Court nomination before President Obama leaves the office.",
    "CatID":15,
    "ClosD":"2016-11-01T00:00:00",
    "SettlD":"2017-01-20T00:00:00",
    "Ru":[{"Name":"Yes","InvDelay":0,"VisDelay":6000},{"Name":"No","InvDelay":0,"VisDelay":6000}],
    "_Type":2,
    "_Period":1,
    "SettlT":0,
    "Comm":0.02,
    "PrivCreator":784741,
    "CreatorName":"USERNAME"}
    

    Comp: Competition CatID: Category (see A2)) ClosD: Closing Date SettlD: Resolution Date Ru: InvDelay must always be 0, VisDelay must always be set to 6000 _Type: See A2) _Period: See A2) SettlT: For settlement types see A2) Comm: 0.02 - must always be 0.02. PrivCreator: must match your userid and will remain privat CreatorName: must match your Username and is public

    Returns: Market ID (no json)

    Create Order (62)

    Note: (use requestID 61 for market making)

    signature|nonce|userid|1062|marketid|runnerid|bidorask|price|amount|type|matchesubuser|pendingperiod
    

    Example:

    signature|nonce|userid|1062|71601335718|0|1|1.56|100.1|2|testorder|6000
    

    Market ID: on which market the order will be placed Runner ID: on which runner the order will be placed: 0 for the 1st runner, 1 for the 2nd runner of the market and so on. BidorAsk: 0 places a bid order, against the runner. 1 places a bet on the runner to win. price: the decimal odds at which the order is placed amount: the amount in mBTC matchedsubuser: custom string type: see unmatched order types in A2) pendingperiod:s should be set to 6000ms

    Returns: unmatched order object https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/UnmatchedOrder.cs

    Cancel Order (15)

    signature|nonce|userid|1015|marketid|runnerid|orderid
    

    Returns: a list of all corresponding matched orders objects for the cancelled unmatched order.

    Cancel Market Orders (10)

    Cancel all opened orders on specific market

    signature|nonce|userid|1010|marketID
    

    Returns: how many unmatched orders were cancelled:

    2 Orders were cancelled`

    Cancel All Orders (16)

    signature|nonce|userid|16
    

    Returns: how many unmatched orders were cancelled:

    5 Orders were cancelled

    Change Order (17)

    signature|nonce|userid|1017|marketid|runnerid|orderid|price|amount
    

    Is a combination of "cancel order" and "create order"

    Returns: unmatched order object https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/UnmatchedOrder.cs

    Bulk Change Order Maker (109)

    Changes, cancels and creates many orders at once.

    signature|nonce|userid|1109|Array of Request ChangeOrder object
    

    https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/REQChangeOrder.cs

    Example

    [{"Mid":73911957931,"Rid":13,"Oid":635980470611670494,"Type":1,"Am":1665.0,"Pri":5.587,"Sub":null,"Boa":0,"Mct":0},{"Mid":73395769791,"Rid":0,"Oid":635980470611720522,"Am":9355.0,"Pri":0.0,"Sub":null,"Boa":1,"Mct":0},{"Mid":73569399509,"Rid":0,"Oid":6359804706645670494,"Am":193.0,"Pri":49.800,"Boa":0,"Mct":0},{"Mid":73570791053,"Rid":2,"Oid":-1,"Am":1514.0,"Pri":6.954,"Sub":"myLine","Boa":1,"Mct":6000}]
    

    Returns: an array of REQChangeOrder objects. The Res property of each object contains the status of each bet. Res is either a serialized UnmatchedOrder order object (https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/UnmatchedOrder.cs) or contains an error message like (Res = ) "YError: Market closed" for example.

    Get New Orders (24)

    signature|nonce|userid|1024|TimeinTicks
    

    TimeinTicks: Time given in ticks, all orders after the given tick will be returned

    Returns: all unmatched orders and matched orders that were created, cancelled or changed after the given time.

    https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/ReturnUOrder.cs https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/ReturnMOrder.cs

    Get Unmatched Orders (25)

    signature|nonce|userid|1025|TimeinTicks
    

    TimeinTicks: Time given in ticks, all orders after the given tick will be returned

    Returns: all matched orders that were created, cancelled or changed after the given time. https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/ReturnMOrder.cs

    Get Matched Orders (27)

    signature|nonce|userid|1027|TimeinTicks
    

    TimeinTicks: Time given in ticks, all orders after the given tick will be returned

    Returns: all matched orders that were created, cancelled or changed after the given time. https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/ReturnMOrder.cs

    Transfer Founds/Withdraw (81)

    signature|nonce|userid|1081|transferobject
    

    Example for transfer object:

    {"FromU":777888,"ToU":777889,"Descr":"test transfer","TType":1,"Amount":2.0}
    

    FromU: must match your userid ToU: must be an existing user TType: custom field, can have any int value

    Returns: transferobject if successful

    Get User Transaction (82)

    signature|nonce|userid|1082|TimeinTicks
    

    Get all user transactions since given time in ticks.

    Returns: An array of transactions. https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/MUserTransfer.cs Every transaction has currency IDs in it. https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/CurrencyIds.cs

    Set Market Maker (73)

    signature|nonce|userid|1073|lmsrmarketmakerobject
    

    This sets up an fully automated LMSR market maker. Google the term to get familiar with the usage.

    example for lmsrmarketmakerobject:

    {"UserID":777888,
    "Runner":5,
    "Enabled":true,
    "InitShareLimit":350.0,
    "B":1300.0,
    "CancelAll":"2016-06-05T13:34:56", 
    "ShareStop":1400.0,
    "InitProb":[0.3,0.1,0.2,0.2,0.2],
    "DiminishBack":[0.01,0.01,0.01,0.0,0.02],
    "DiminishLay":[0.0,0.0,0.0,0.01,0.01],
    "coolOffSeconds":36000.0,"coolOffFactor":4.0}
    

    https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/LMSR.cs

    Default values:

    {"UserID":[userid],
    "Runner":5,
    "Enabled":true,
    "InitShareLimit":300.0,
    "B":1000.0,
    "CancelAll":"2016-06-05T13:34:56", 
    "ShareStop":9999.0,
    "InitProb":[0.2,0.2,0.2,0.2,0.2],
    "DiminishBack":[0.00,0.00,0.00,0.0,0.00],
    "DiminishLay":[0.01,0.01,0.01,0.01,0.01],
    "coolOffSeconds":1.0,"coolOffFactor":2.0}
    

    UserID: must match your userid MarketID: must be provided Runner: # of Runners / must match the # of runners of the market Enabled: must be set to true InitShareLimit (must be > 1): Shares that are offered in one order. Stake + Winnings from one order are 350mBTC B (must be > 10): ~ is about the same as the maxium possible loss of the market maker CancelAll (must be set to a future date): Date where the market maker stops. Set to year 2100 if the mm should run forever ShareStop (must be > 1): amount of exposure in shares before the market maker stops. Should be set higher than B in regular cases. InitProb: the initial probability estimation for all runners DiminishBack (must be non-negative): In general the LMSR market maker runs on 0% margin, i.e. it doesn't make any profit. If more margin should be added, you can worsen the odds for each bid orders for every runner. 0.01 worsens bid odds from 80% to 81% (or 1.25 to 1.2345) for example. DiminishLay: same for all ask orders.

    *Cool off adds temporary additional margin to markets with increased activity and should be applied to markets that can have exogenous shocks or where real probabilities can deviate from the initial probability distribution. *

    coolOffFactor (must be >=1): if set to 4.0 the odds will worsen 4.0 times more than expected from the usual lmsr market maker. coolOffSeconds (must be >=1): The time after which the coolOff period will be over. If set to 36000 the additional market margin will reduce step by step over an period of 10 hours.

    If no cool off is required, set coolOffSeconds to 1.

    Disable a MM by setting Enabled = false and other variables to a valid value.

    Get Marker Maker (70)

    Gets the current LMSR MM from the user for a given market.

    signature|nonce|userid|1070|marketid
    

    example for lmsrmarketmakerobject:

    shell{"UserID":777888,"MarketID":61659266392,"Runner":5,"Enabled":true,"InitShareLimit":350.0,"B":1300.0,"CancelAll":"2016-06-05T13:34:56", "ShareStop":1400.0,"InitProb":[0.3,0.1,0.2,0.2,0.2],"DiminishBack":[0.01,0.01,0.01,0.0,0.02],"DiminishLay":[0.0,0.0,0.0,0.01,0.01],"coolOffSeconds":36000.0,"coolOffFactor":4.0}

    Change Market Closing Time (84)

    Changes Closing and Settlement Date

    signature|nonce|userid|1084|ChangeTimeObject
    

    Example:

    {"MID":76650963889,
    "ClosD":"2016-06-11T01:00:00Z",
    "SetlD":"2016-06-11T03:00:00Z"}
    

    https://github.com/Fairlay/FairlayDotNetClient/blob/master/src/Private/Datatypes/ChangeTimeReq.cs

    Returns: MarketTime changed.

    Get Settlements (85)

    Gets all bankroll adjustments after a given time.

    signature|nonce|userid|1085|timeinticks
    

    Returns: A JSON encoded Statement Object:

    long ID: is not unique globally; is the time in milliseconds from Jan 1th 2016 Descr: optional description, contains the market ID in case of a settlement. T: 0-99 stands for a transfer (same like ttype in transfer object) includes deposits & cashouts, 100 admin, 200 market settlement w/o commission, 201 market settlement with commission, 250 unsettlement, 300 commission bonus) Am: amount credited Bank: total bankroll after the adjustment.

    Settle Market (86)

    Settles a given market. Note that the total betting volume of the market will be deducted from the available balance for 2 to 3 days. Unless the user has special rights, a user can only settle markets he created.

    signature|nonce|userid|1086|SettleRequestObject
    

    Example:

    signature|nonce|userid|1086|{
    "Mid":77588905280,
    "Runner":0,
    "Win":1,
    "Half":false,
    "Dec":0.0,
    "ORed":0.0}
    

    Mid: is the market ID Runner: determines the Runner which won (0 means that the 1st Runner won, 1 means that the 2nd Runner won and so on). If a market shall be voided the Runner must be set to -1 Win: Must be set to 1 Half: should be set to "false". Only needed for +- 0.25 and +-0.75 soccer spread and over/under markets. If a market is half won or half lost, set Half to "true"; Dec: If the market is not binary, but has a decimal outcome, this needs to be set to the result. [Not supported yet] ORed: Odds reduction [only for Horse racing - not needed in general]

    Returns: "Market settled" or some kind of "XError: ..."

    Data Types

    Market Category

    The main categories for diverse market options, use their IDs to filter market by category:

        MARKET_CATEGORY = {
            1: 'Soccer',
            2: 'Tenis',
            3: 'Golf',
            4: 'Cricket',
            5: 'RugbyUnion',
            6: 'Boxing',
            7: 'Horse Racing',
            8: 'Motorsport',
            10: 'Special',
            11: 'Rugby League',
            12: 'Bascketball',
            13: 'American Football',
            14: 'Baseball',
            15: 'Politics',
            16: 'Financial',
            17: 'Greyhound',
            18: 'Volleyball',
            19: 'Handball',
            20: 'Darts',
            21: 'Bandy',
            22: 'Winter Sports',
            24: 'Bowls',
            25: 'Pool',
            26: 'Snooker',
            27: 'Table tennis',
            28: 'Chess',
            30: 'Hockey',
            31: 'Fun',
            32: 'eSports',
            33: 'Inplay',
            34: 'reserved4',
            35: 'Mixed Martial Arts',
            36: 'reserved6',
            37: 'reserved',
            38: 'Cycling',
            39: 'reserved9',
            40: 'Bitcoin',
            42: 'Badminton'
        }
    

    Market Type

    Different types of market rules settlement:

        MARKET_TYPE = {
            0: 'MONEYLINE',
            1: 'OVER_UNDER',
            2: 'OUTRIGHT',
            3: 'GAMESPREAD',
            4: 'SETSPREAD',
            5: 'CORRECT_SCORE',
            6: 'FUTURE',
            7: 'BASICPREDICTION',
            8: 'RESERVED2',
            9: 'RESERVED3',
            10: 'RESERVED4',
            11: 'RESERVED5',
            12: 'RESERVED6'
    
        }
    

    Market Periods

    Mostly used by sports markets, define if the market is related to a specific fraction of the match:

        MARKET_PERIOD = {
            0: 'UNDEFINED',
            1: 'FT',
            2: 'FIRST_SET',
            3: 'SECOND_SET',
            4: 'THIRD_SET',
            5: 'FOURTH_SET',
            6: 'FIFTH_SET',
            7: 'FIRST_HALF',
            8: 'SECOND_HALF',
            9: 'FIRST_QUARTER',
            10: 'SECOND_QUARTER',
            11: 'THIRD_QUARTER',
            12: 'FOURTH_QUARTER',
            13: 'FIRST_PERIOD',
            14: 'SECOND_PERIOD',
            15: 'THIRD_PERIOD',
        }
    

    Market Settlements

    Different types of markets settlement:

        MARKET_SETTLEMENT = {
            0: 'BINARY',
            1: 'CFD',
            2: 'CFDI',
            3: 'EXCHANGE'
        }
    

    Matched order state

    States of an order could have during its lifetime:

        MATCHED_ORDER_STATE = {
            0: 'MATCHED',
            1: 'RUNNER_WON',
            2: 'RUNNER_HALFWON',
            3: 'RUNNER_LOST',
            4: 'RUNNER_HALFLOST',
            5: 'MAKERVOIDED',
            6: 'VOIDED',
            7: 'PENDING',
            8: 'DECIMAL_RESULT'
        }
    

    Unmatched order state

    States of unmatched order could have during its lifetime:

        UNMATCHED_ORDER_STATE = {
            0: 'ACTIVE',
            1: 'CANCELLED',
            2: 'MATCHED',
            3: 'MATCHEDANDCANCELLED'
        }
    

    Order type

    Different types of order that is created: - MAKERTAKER : If not matched instantly, will remain in the orderbook. - MAKER : Will be placed at orderbook waiting for a match. - TAKER : If not fully matched instantly, the amount unmatched will be voided automatically.

        ORDER_TYPE = {
            0: 'MAKERTAKER',
            1: 'MAKER',
            2: 'TAKER'
        }
    

    Public API Introduction

    This is a free service to scrape all markets on Fairlay. For all POST requests (creating/changing markets and orders) use the paid Private API.

    For more examples how this API should be used together with our paid API, please take a look at our sample clients in C# and Python.

    Please feel free to comment and make suggestions.

    Public API Calls

    Free Servers

    http://31.172.83.181:8080

    used by default for all Public API calls

    http://31.172.83.53:8080

    (is an alternate server with the same functionality, also used for all Private API calls)

    Methods

    For examples on how to use each of the API calls presented here, see the C# Unit Tests.

    In all of the examples below you can call /free/(method) calls with /free0/ up to /free9/ to increase the given limits above, a simple way is to either rotate from 1 to 9 or just randomize the free call from 1 to 9.

    Server Time

    Returns the server time in ticks.

    http://31.172.83.181:8080/free/time

    Note: You can do the same in the Private API via getservertime

    Markets

    Returns JSON encoded list of markets that apply to the given filter.

    http://31.172.83.181:8080/free/markets/JSON-ENCODED-MARKETFILTER

    MARKETFILTER object looks like this:

    {
            "Cat":0,
            "RunnerAND":["Arsenal","Chelsea"],
            "TitleAND":null,
            "TitleNOT":["Corners","Throwin"],
            "Comp":"Premier League",
            "TypeOR":[0],
            "PeriodOR":[1],
            "SettleOR":null,
            "Descr":null,
            "ChangedAfter":"2016-01-01T22:01:01",
            "SoftChangedAfter":"0001-01-01T00:00:00",
            "OnlyActive":false,
            "NoZombie":false,
            "FromClosT":"2016-05-01T00:00:00",
            "ToClosT":"0001-01-01T00:00:00",
            "FromID":0,
            "ToID":10000
    }
    

    Cat: Category, see A2) for more information. 0 queries all Categories. TitleAND: List of strings which all must appear in the title of the market. RunnerAND: List of strings which all must be contained in at least one name of one runner of the market. TitleNOT: List of strings which none may appear in the title of the market. Comp: Competition name. null to get all competitions. **TypeOr8: Market Types, see A2) for more information. Only the Market Types given will be returned. If set to null, all market types will be returned. PeriodOr: Market Period, see A2) for more information. SettleOr: Settlement Type, see A2) for more information. NoZombie: If True, no empty markets will be returned (without any open order). Descr: The given string must appear in the market description. ••ChangedAfter••: Return markets where the meta data was changed after the given date. Usually the Closing and Settlement Dates of a market is the only data that changes. SoftChangedAfter: Return all markets, where either the the meta data or the orderbook has changed since the given date. FromClosT: Return markets where the closing time is greater than the given one. FromID and ToID: Use for paging requests. ToID has a default value of 300 if not set.

    Examples:

    Returns the first 100 non-empty soccer markets, where one of the runners is Portugal, the Title does not contain the words "Corners" or "Throwin" and the period of the match is full-time.

    http://31.172.83.181:8080/free/markets/{"Cat":1,"NoZombie":true,"RunnerAND":["Portugal"], "TitleNOT":["Corners","Throwin"], "PeriodOR":[1],"FromID":0,"ToID":100}
    

    Returns all active tennis matches of the type Over/Under or Outright where the odds or market data have changed after June 1st 12:01:30pm.

    http://31.172.83.181:8080/free/markets/{"Cat":2,"TypeOr":[1,2],"SoftChangedAfter":"2016-06-01T12:01:30","OnlyActive":true,"ToID":10000}
    

    Returns all active non-empty markets.

    http://31.172.83.181:8080/free/markets/{"OnlyActive":true,"NoZombie":true,"ToID":100000}
    

    Competitions

    Returns all competitions in the selected category.

    http://31.172.83.181:8080/free/comps/CATEGORYID

    Example for all soccer competitions:

    http://31.172.83.181:8080/free/comps/1

    API Libraries & Source Code