Skip to main content

GetBetsService

A list of all methods in the GetBetsService service. Click on the method name to view detailed information about that method.

MethodsDescription
BetsGetBetsByTypeV4AsyncReturns bets. ### Get running bets by time range: https://api.pinnacle.com/v4/bets?betlist=RUNNING&fromDate=2017-11-21T00:00:00Z&toDate=2017-11-29T00:00:00Z Running bets are queried by placedAt date time ### Get settled bets by time range: https://api.pinnacle.com/v4/bets?betlist=SETTLED&fromDate=2015-12-28T00:00:00Z&toDate=2015-12-29T00:00:00Z Settled bets are queried by settledAt date time https://api.pinnacle.com/v4/bets?betlist=SETTLED&fromDate=2017-11-20T00:00:00Z&toDate=2017-11-23T00:00:00Z ### Get settled cancelled bets by time range: https://api.pinnacle.com/v4/bets?betList=SETTLED&fromDate=2018-03-01&toDate=2018-03-28&betStatuses=CANCELLED ### Get bets by bet ids: https://api.pinnacle.com/v4/bets?betIds=775856112,775856113,775856114 ### Get bets by uniqueRequestIds: https://api.pinnacle.com/v4/bets?uniqueRequestIds=62335222-dae4-479a-8c05-46440ccdd3bb,42335222-dae4-479a-8c05-46440ccdd3bb

BetsGetBetsByTypeV4Async

Returns bets. ### Get running bets by time range: https://api.pinnacle.com/v4/bets?betlist=RUNNING&fromDate=2017-11-21T00:00:00Z&toDate=2017-11-29T00:00:00Z Running bets are queried by placedAt date time ### Get settled bets by time range: https://api.pinnacle.com/v4/bets?betlist=SETTLED&fromDate=2015-12-28T00:00:00Z&toDate=2015-12-29T00:00:00Z Settled bets are queried by settledAt date time https://api.pinnacle.com/v4/bets?betlist=SETTLED&fromDate=2017-11-20T00:00:00Z&toDate=2017-11-23T00:00:00Z ### Get settled cancelled bets by time range: https://api.pinnacle.com/v4/bets?betList=SETTLED&fromDate=2018-03-01&toDate=2018-03-28&betStatuses=CANCELLED ### Get bets by bet ids: https://api.pinnacle.com/v4/bets?betIds=775856112,775856113,775856114 ### Get bets by uniqueRequestIds: https://api.pinnacle.com/v4/bets?uniqueRequestIds=62335222-dae4-479a-8c05-46440ccdd3bb,42335222-dae4-479a-8c05-46440ccdd3bb

  • HTTP Method: GET
  • Endpoint: /v4/bets

Parameters

NameTypeRequiredDescription
betlistBetlistType of bet list to return. Not needed when betids is submitted.
betStatusesList<BetStatuses>Type of bet statues to return. This works only in conjustion with betlist, as additional filter.
fromDatestringStart date of the requested period. Required when betlist parameter is submitted. Start date can be up to 30 days in the past. Expected format is ISO8601 - can be set to just date or date and time.
toDatestringEnd date of the requested period. Required when betlist parameter is submitted. Expected format is ISO8601 - can be set to just date or date and time. toDate value is exclusive, meaning it cannot be equal to fromDate.
sortDirSortDirSort direction by postedAt/settledAt. Respected only when querying by date range.
pageSizelongPage size in case. Max is 1000. Respected only when querying by date range.
fromRecordlongStarting record (inclusive) of the result. Respected only when querying by date range. To fetch next page set it to toRecord+1
betidsList<long>A comma separated list of bet ids. When betids is submitted, no other parameter is necessary. Maximum is 100 ids. Works for all non settled bets and all bets settled in the last 30 days.
uniqueRequestIdsList<string>A comma separated list of uniqueRequestId from the place bet request. If specified, it's highest priority, all other parameters are ignored. Maximum is 10 ids. If client has bet id, preferred way is to use betIds query parameter, you can use uniqueRequestIds when you do not have bet id. That are 2 cases when client may not have a bet id: 1. When you bet on live event with live delay, place bet response in that case does not return bet id, so client can query bet status by uniqueRequestIds. 2. In case of any network issues when client is not sure what happened with his place bet request. Empty response means that the bet was not placed. Please check Deduplication section for more details. Note that there is a restriction: querying by uniqueRequestIds is supported for straight and special bets and only up to 30 min from the moment the bet was place.
betTypeList<BetsGetBetsByTypeV4BetType>A comma separated list of bet types.

Return Type

GetBetsByTypeResponseV4

Example Usage Code Snippet

using PinnacleBets;
using PinnacleBets.Models;

var client = new PinnacleBetsClient();

var betStatuses = new List<BetStatuses>() { BetStatuses.Won };
var betids = new List<long>() { 9 };
var uniqueRequestIds = new List<string>() { "uniqueRequestIds" };
var betType = new List<BetsGetBetsByTypeV4BetType>() { BetsGetBetsByTypeV4BetType.Spread };

var response = await client.GetBets.BetsGetBetsByTypeV4Async(Betlist.Settled, betStatuses, "fromDate", "toDate", SortDir.Asc, 1000, 0, betids, uniqueRequestIds, betType);

Console.WriteLine(response);

Build Your Own SDKs with  liblab

Build developer friendly SDKs in minutes from your APIs

Start for Free →