Skip to content

Releases: Azuro-protocol/toolkit

v6.4.0

Choose a tag to compare

@on47sky on47sky released this 09 Jul 09:02

What's new
Per-outcome state, condition categories & market sorting

  • New OutcomeState enum (Active / Canceled / Stopped / Won / Lost) and ConditionCategory type.
  • Per-outcome hidden & state — added to OutcomeData (getConditionsByGameIds) and to
    ConditionStateData.outcomes[] (getConditionsState). An individual outcome can now be suspended or hidden
    while the rest of its condition stays open for betting.
  • category added to ConditionDetailedData; sort + category added to ConditionStateData.
  • groupConditionsByMarket:
    • Market and MarketCondition now carry category; each MarketCondition exposes its own sort;
      MarketOutcome gains hidden + state.
    • Returned markets are ordered by their first condition's sort (ascending).
    • The per-condition shape is now exported as MarketCondition (previously an internal Condition).
    • Empty / nullish input now returns [] instead of throwing.

Note

MarketOutcome and the raw OutcomeData gained required hidden / state fields. Reading API
responses is unaffected (you just get more data), but code that constructs these objects by hand must add
the new fields.

Docs:
groupConditionsByMarket
getConditionsByGameIds
getConditionsState

Full Changelog: v6.3.1...v6.4.0

v6.3.1

Choose a tag to compare

@on47sky on47sky released this 09 Jul 08:58

Fixes

  • getPredefinedCombo falls back to the dictionary market/selection name (or 'Unknown' for
    new-generation conditions) when the API returns an empty-string title — previously only null /
    undefined triggered the fallback, so blank titles from the API were passed through as-is.

Full Changelog: v6.3.0...v6.3.1

v6.3.0

Choose a tag to compare

@on47sky on47sky released this 09 Jul 08:56

Predefined combo bets — ready-made express selections, each a list of conditions with a precomputed totalOdds.

  • getPredefinedCombo({ chainId }) — fetches the curated combos for a chain's environment. Each returned
    PredefinedComboConditionData pins a single picked outcome (the API's outcomes field is normalized to
    a singular outcome).
  • New exported types: GetPredefinedComboParams, GetPredefinedComboResult, PredefinedComboData,
    PredefinedComboConditionData.

Docs: https://gem.azuro.org/hub/apps/toolkit/feed/getPredefinedCombo

Full Changelog: v6.2.0...v6.3.0

v6.2.0

Choose a tag to compare

@on47sky on47sky released this 30 May 20:15

Features

Dynamic markets & richer condition data

  • Added support for the new dynamic markets ("5…" conditions) that are managed via API and are not present in the dictionaries package.
  • getConditionsByGameIds now accepts an extended?: boolean flag. Set it to true to receive the new dynamic conditions in the response (defaults to false).
  • ConditionDetailedData now exposes market/outcome titles directly, plus new fields for grouping and presentation:
    • title is now always present (no longer nullable).
    • New sort, marketId and marketVarietyId fields on the condition.
    • Outcomes are now typed via the exported OutcomeData type and carry title, sort, and a point field (numeric handicap/line value such as "-2.5" for modern conditions).
  • groupConditionsByMarket reworked to group both legacy and new dynamic markets (split into legacy and v5 grouping internally).

SIWE authentication

  • New auth utilities for Sign-In With Ethereum:
    • getSiweNonce — request a nonce from the API.
    • buildSiweMessage — build the SIWE message to be signed.
    • verifySiwe — verify the signed message and obtain a session token.

User favorites

  • New API helpers to manage a user's favorite countries and leagues:
    • getUserFavorites
    • createUserFavorite (requires user auth token)
    • deleteUserFavorite (requires user auth token)
  • New exported types: Favorites, FavoriteCountry, FavoriteCountryRef, FavoriteLeague, FavoriteSport.

Full Changelog: v6.1.1...v6.2.0

v6.1.0

Choose a tag to compare

@on47sky on47sky released this 23 Apr 10:17
  • support new field isTopLeague for leagues from API
  • add new filter topLeagueFilter to getSports
  • add deprecation marks for discontinued envs

Full Changelog: v6.0.2...v6.1.0

v6.0.2

Choose a tag to compare

@on47sky on47sky released this 31 Mar 10:45
  • add hidden field to ConditionDetailedData type, pass it in groupConditionsByMarket
  • fix default sorting for getSports
  • pass environment in getConditionsState request for more accurate results in edge cases

Full Changelog: v6.0.1...v6.0.2

v6.0.0

Choose a tag to compare

@on47sky on47sky released this 16 Mar 11:17

Toolkit v6.0.0:

  • New Feed REST API utilities for fetching games and conditions that replace the deprecated and removed GraphQL feed queries:
    • getConditionsByGameIds - replaces Conditions query
    • getConditionsState - replaces ConditionsBatch query
    • getGamesByFilters - replaces Games query
    • getGamesByIds - replaces Game query and Games when you need to fetch multiple games by ID
    • getNavigation - replaces Navigation and NavigationSport queries
    • getSports - replaces Sports query
    • searchGames - new one to search games by text query
  • New getBetsByBettor method for v3 bets history, including preparing orders
  • getBetCalculation replaces the deprecated getMaxBet (it now requires user account address for accuracy and returns minBet and maxBet).
  • Improved typing system
  • Extended enum GameState
  • Extended enum BetStatus to include pending bet orders
  • Renamed and extended enum BetStateBetOrderState
  • Helper getBetStatus now requires BetOrderState from bet entity (in case of bets fetched from graphql feed, pass null)
  • Fixed typo: calcMindOddscalcMinOdds
  • Added field redeemedAt to legacy bets graphql doc
  • Removed Data Feed graphql documents and types

Full Changelog: v5.1.9...v6.0.0

Migration Guide

v5.1.8

Choose a tag to compare

@CleanBread CleanBread released this 30 Jan 10:35

Changed api and graph endpoints

v5.1.7

Choose a tag to compare

@on47sky on47sky released this 15 Dec 12:37

bump version (fixes v5.1.6 build)

v5.1.6

Choose a tag to compare

@on47sky on47sky released this 15 Dec 12:35

update calcMinOdds for combo bets