7.1 addFeatureBuy()

Gives $players feature buy promotion for the $game. They are valid until $validTo.

public addFeatureBuy( [ string $title = string(0) "" , string $players , string $games , string $available , string $validTo , string $validFrom = string(0) "" ] )

Parameters

  • string $title string(0) "" - Default = ""
  • string $playerids required - Value of the variable looks like 220650,124144 or 220650. Note that there nuber are EXAMPLES
  • string $gameids required - Value of the variable looks like 787,789 or 787. Note that these numbers are EXAMPLES
  • string $validTo string(0) "" - Default = + 1 week 
  • string $validFrom string(0) "" - Default = ""
  • string $betlevel string(0) "" - Default = "" - Possible values are: min, mid, max. It defines the cost of the bet during the feature buy. Note: feature buy promotions can on average be worth between 50-100€ on min bet, so mid and max are worth even more.

Return Values

  • type - String

Example: The value of paramater $playerids can be: 220650,124144,2359283 or just 220650


The same is with the parameter $games

REST REQUEST
Array
    (
        [api_password] => xapitest
        [api_login] => xapitest
        [method] => addFeatureBuy
        [tittle] => featurebuy 1
        [playerids] => "220650,124144"
        [gameids] => "787,789"
        [validTo] => 2016-05-11
		[validFrom] => ""
		[betlevel] => ""
		[currency] => EUR
    )


REST RESPONSE
ON ERROR
1,addFeatureBuy: [text error]
ON SUCCESS
{
	"error": 0,
	"response": "{\"created\":1,\"featurebuy_id\":\"5b8fc08970d5544676009e24\"}",
	"currency": "EUR"
}


Source Code
public function addFeatureBuy($title = '', $players, $games, $validTo, $validFrom = '', $betLevel = ''){
	return $this->client->addFeatureBuy($title, $players, $games, $validTo, $validFrom, $betLevel);
}

Deep dive into freerounds

Once player enters the game in which he has featurebuy all subsequent debit and credit requests will have param "featurebuy_id" with id that is returned in addFeatureBuy() response.  There is no way to know actual value of the freeround - usually min is min possible bet in the game, mid next possible bet and max third possible bet.

"validFrom" time will start at 00:00 and "validTo" will end at 23:59 server time (CET).

Featurebuys will be added for all players from "playerids" that open any game from "gameids". Each player will get featurebuy only in the first game that is opened and is in "gameids".