Skip to content

Show interest in another team's player

POST
/api/players/nonce/{nonce}/interest
curl --request POST \
--url https://foxleague.ai/api/players/nonce/1/interest \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "offer_foxsy": 1, "share_telegram": true }'

Tells the owner of another team’s card that you are interested in it. You can name an offer in whole FOXSY (offer_foxsy): it binds nobody, no FOXSY moves and nothing is reserved. With share_telegram the owner also sees your Telegram username; it needs a Telegram account linked to your team in Settings, with a username. There is no message field: a body with any other field is refused. The owner sees your team name and coach name, the offer, the time and the username only when you share it.

The owner gets one notification per card and UTC day: the first interest of the day creates it with a push, every later one rewrites it (how many managers, the best offer) without a second push. When the owner lists the card, every manager interested in it during the last 7 days is told. The listing is public: anyone can buy it first.

Who: a signed-in player with a team, about a card of another team that is not on the market.

Limits: player_interest.per_day interests a UTC day (5) and one per card and owner every player_interest.repeat_days days (7), both in GET /api/config. After the card changes hands you can tell its new owner at once.

Refusals:

  • Showing interest in a player is not available right now.: the feature is switched off.
  • Player not found.: no card has this nonce.
  • This is your own player.: the card is in your squad.
  • This player is already on the market: you can buy it there.: the card is listed.
  • This player is not in a team's squad right now.: the card is in a wallet without a team.
  • Connect Telegram with a username in Settings first. You can also send without sharing it.: share_telegram without a linked username.
  • An offer that is not a whole number of FOXSY from 1 to 1000000000.
  • The daily limit and the limit of one interest per card and owner in the repeat window, each with the number in its words.

A body that is not this JSON (a field of the wrong type, an unknown field such as a message) is answered HTTP 422 with a plain text body.

nonce
required
integer format: int64

The NFT nonce of the card.

Media type application/json

Your interest in a card: an optional offer and the Telegram opt-in. Nothing else is taken.

object
offer_foxsy

Your offer in whole FOXSY, from 1 to 1000000000. Leave it out for no offer. It binds nobody and moves no FOXSY.

integer | null format: int64
share_telegram

true shows your Telegram username to this card’s owner. Needs a Telegram account with a username linked in Settings. Default false.

boolean
Example generated
{
"offer_foxsy": 1,
"share_telegram": true
}

Success or a refusal: read success (the refusals are in the description).

Media type application/json
object
code

A machine-readable reason next to error, set only where the caller must act differently. tx_pending: the payment was not refused but could not be verified yet; keep the transaction hash and confirm again with the same hash, never pay twice.

string | null
data

The answer. Present when success is true.

object
per_day
required

How many you can send in a UTC day.

integer format: int64
sent_today
required

Interests you sent today (UTC), this one included.

integer format: int64
error

Why the request was refused, in plain words. Present when success is false.

string | null
success
required

true when the request did what it asked. false is a refusal: read error.

boolean
Example
{
"data": {
"per_day": 5,
"sent_today": 1
},
"success": true
}

No valid session. The body is plain text: Missing Authorization header, Invalid Authorization format, Invalid session token or Session expired or invalid. Sign in again.

Media type text/plain
string
Example
Session expired or invalid