____  ___    _  _     _   _ _____     _______
 / ___|/ _ \  | || |   | | | |_ _\ \   / / ____|
| |  _| | | | | || |_  | |_| || | \ \ / /|  _|
| |_| | |_| | |__   _| |  _  || |  \ V / | |___
 \____|\___/     |_|   |_| |_|___|  \_/  |_____|

 --- A GOPHER-LIKE INTERFACE FOR HIVE BLOCKCHAIN ---

Modern & Wild API Changes

BY: @splinterlands | CREATED: June 29, 2022, 3:31 p.m. | VOTES: 395 | PAYOUT: $28.93 | [ VOTE ]

[IMAGE: https://i.imgur.com/R9h9VQZ.jpg]
[IMAGE: https://i.imgur.com/efJwvul.png]

This information is a compilation of arcane tradecraft that will only interest third party developers using the Splinterlands API. If you are not a developer, the below (while potentially insightful if you are technically minded) will likely not be of much interest and you should probably stop reading now.

Definition of Modern and Wild cards

Format Cards Allowed Wild All Modern Chaos Legion, Dice, Untamed, Reward & Promo cards with an Untamed or Chaos Legion style frame are all considered Modern cards.

Technical definition: any card that has an edition in [4,5,7], OR tier in [3,4,7] is considered to be Modern.

For all APIs that return player data (including but not limited to those mentioned below), new fields have been added that contain Modern stats. These new fields will be in addition to the original stats (which are now interpreted as being for the Wild format). All such fields will be prefixed with modern_. Data not explicitly prefixed with modern_ should be assumed to be Wild data.

For all APIs that return battle data, there will be a new field format included in the response data. This field will be set to modern if it is defined. If it is undefined, the battle should be taken to be a Wild battle.

API List

settings (also accessible in the browser console as SM.settings)

Added the following fields:

Removed the following fields:

Example: https://qa.splinterlands.com/settings

players/season_ratings

This API is no longer supported and any attempt to use it will return an error message.

players/quests

The league field has been removed from response data.

Example: https://qa.splinterlands.com/players/quests?username=farpetrad

players/refresh_season_data

Response data now includes additional information about Modern stats. Data not explicitly prefixed with modern_ should be assumed to be Wild data. current_modern_season_player and previous_modern_season_player fields have been added that function equivalently to their Wild counterparts. Note that these optional fields will not be defined if the player has not played any Modern battles in the corresponding seasons.

Example: https://qa.splinterlands.com/players/refresh_season_data?token=XXXXXXXXXX&username=myname

players/refresh

Response data now includes additional information about Modern stats. Data not explicitly prefixed with modern_ should be assumed to be Wild data.

Example: https://qa.splinterlands.com/players/refresh?token=XXXXXXXXXX&username=myname

players/details

Added an optional format query parameter, which if used must be set to either modern or all. This parameter only makes a difference if used in combination with the seasondetails parameter. It determines whether the returned season_details object is for Wild or Modern. If format is not present, then the API will default to giving season_details results only for the Wild format.

A new field player_uuid has also been added, containing the unique UUID for the queried player.

Valid values for seasondetails (this must be a string value):

Valid values for format (this must be a string value):

Example: https://qa.splinterlands.com/players/details?name=brybro27&season_details=true&format=modern

players/details_by_id

Added an optional format query parameter. The format and seasondetails parameters now obey the same rules & support the same values as explained above for the players/details API. This API functions the same way, except players/details_by_id allows lookup by the unique UUID rather than player name.

Example: https://qa.splinterlands.com/players/details_by_id?id=d4bb773d-d36d-484b-918b-335c040148d4&season_details=only&format=all

players/dec

New fields modern_inflation and modern_reward_pool have been added to the response data.

Example: https://qa.splinterlands.com/players/dec

players/leaderboard_with_player

Added an optional format query parameter, which if used must be set to modern. If format is not present, then the API will default to giving results only for the Wild format.

Example: https://qa.splinterlands.com/players/leaderboard_with_player?username=farpetrad&season=89&leaderboard=2&format=modern

players/leaderboard

Added an optional format query parameter, which if used must be set to modern. If format is not present, then the API will default to giving results only for the Wild format.

Example: https://qa.splinterlands.com/players/leaderboard?season=89&leaderboard=2&format=modern

players/recent_teams

Added an optional format query parameter, which if used must be set to modern. If format is not present, then the API will default to giving results only for the Wild format.

Example: https://qa.splinterlands.com/players/recent_teams?player=brybro27&format=modern

battle/history

Added an optional format query parameter, which can be set to modern or wild. If format is not present, then the API will default to giving results for both formats mixed together.

Example: https://qa.splinterlands.com/battle/history?player=brybro27&format=modern

battle/history2

Added an optional format query parameter, which if used must be set to modern. If format is not present, then the API will default to giving results only for the Wild format.

Example: https://qa.splinterlands.com/battle/history2?player=$top&leaderboard=2&format=modern

Blockchain Transaction Changes

Tournaments

A new field epoch has been added to the allowed_cards tournament settings data. If present, epoch will be either modern or wild. For older tournaments, epoch may not be defined. If epoch is not defined, the tournament will be treated as a Wild tournament.

Modern tournaments only allow Modern cards to be used. In such tournaments, all other settings such as edition restrictions, gold foil rules, etc still apply as usual.

Also note that in Modern tournaments, only Modern cards count towards Collection Power entry requirements, and entry fee discounts are based on the player’s Modern league. For Wild tournaments, entry fee discounts are based on the player’s Wild league.

Example: https://qa.splinterlands.com/tournaments/find?id=18d8886db38128a011290d76d76261e48f869b1c

[IMAGE: https://i.imgur.com/4KaGHEP.png]

Important Note

The API examples given above are only that, examples of how such queries should be formed. They are not guaranteed to actually return data, as the state of the QA environment constantly changes.

Also, before testing your app against QA, you should confirm in the Splinterlands Discord that Modern & Wild has actually been deployed there. At the time of writing, it has not. Expect that it will be soon, and a notice will be given in the developers-3rd-party channel.

[IMAGE: https://i.imgur.com/IAAas02.png]

Stay tuned for more updates from the Splinterlands!

Website | Blog | Discord | Telegram | Shop

[IMAGE: https://i.imgur.com/xrZQl2D.gif]

NOTE: All rewards from this post will be burned.

TAGS: [ #modern ] [ #wild ] [ #api ] [ #splinterlands ] [ #spt ] [ #community ] [ #play2earn ] [ #gaming ]

Replies

@poshtoken | July 2, 2022, 9:47 p.m. | Votes: 0 | [ VOTE ]

https://twitter.com/splinterlands/status/1543349796609568768
The rewards earned on this comment will go directly to the people sharing the post on Twitter as long as they are registered with @poshtoken. Sign up at https://hiveposh.com.

[ BACK TO TRENDING ] [ BACK TO MENU ]
CMD>