sorare / api

Sorare API documentation
152 stars 47 forks source link

BUG - NBA PurePlay - NbaLeaderboard - Authorized cards #584

Closed jmallot21 closed 1 week ago

jmallot21 commented 3 months ago

The myComposeLineupCards.cards method never returns any cards with the position NBA_CENTER.

image

query getNbaLeaderboard{ nbaLeaderboard(slug:"nba-2023-gameweek-46-limited-pure-play"){ displayNameWithoutRarity requirements { minCurrentSeasonCardCount } myComposeLineupCards(includeUsed: true indexInLineup:1 cardsInLineupPartial: []) { nodes { card { slug positions } } } } }

@redox Could you include the missing cards ?

jmallot21 commented 3 months ago

I also noticed something else: The NBA_GUARD cards stand out well. On the other hand, no card only NBA_FORWARD stands out. They are all NBA_FORWARD & NBA_GUARD image

juliengirault commented 3 months ago

@jmallot21 Yesterday we opened a GW with a brand new special weekly: Pure Play.

This leaderboard introduces a major change that is: each slot is now a specific position.

To know whether a leaderboard implements slot positions, you can read leaderboard.requirements.lineupSlotPositions

The myComposeLineupCards endpoint accepts a indexInLineup param that is now critical in order to get the list of eligible cards for each slot. I see you are passing indexInLineup:1 in your query, that's why you are receiving only guards.

For the Pure Play special weekly:

indexInLineup: 0  corresponds to guard
indexInLineup: 1  corresponds to guard
indexInLineup: 2  corresponds to forward
indexInLineup: 3  corresponds to forward
indexInLineup: 4  corresponds to center

Hope this helps!

jmallot21 commented 3 months ago

Hello Julien,

Thank you, this puts a lot of things into question, but it will help me.

Please note that the API documentation is not up to date. image

Where can I track changes made to the APIs? Could the git Readme file be updated?

Thanks

jmallot21 commented 1 week ago

It's ok now. thx image