企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持知识库和私有化部署方案 广告
## 3.4 选手接口 ### 1. 选手列表 GET: ~~~ /sport/api/v1/players ~~~ 接口概述:获取所有选手数据 | 请求参数 | 数据类型 | 是否必填 | 描述 | | --- | --- | --- | --- | | sport_id | int | 是 | 运动ID筛选 | | team_id | int | 否 | 填入队伍ID,可查询某个战队下的所有选手数据 | | day | int | 否 | 可以填写1-7,1代表24小时内变动数据筛选;7代表一周内变动数据筛选,2-6以此类推;若不填写或填写错误此参数不生效 | | language| string | 否 | 1.不填,“name”默认返中文;2. 填vi,字段“name” 返越南文;3.填zh_tw,返繁体| | page | int | 否 | 页数 | | per_page | int | 否 | 每页数据条数 | | token | string | 是 | 客户密钥 | 请求url示例 ~~~ /sport/api/v1/players?page=1&per_page=100&token=XXXXX ~~~ ### 2.选手详情 GET: ~~~ /sport/api/v1/players/{player_id} ~~~ 接口概述:获取选手详情数据 建议频率:查询时调用 | 请求参数 | 数据类型 | 是否必填 | 描述 | | --- | --- | --- | --- | | player_id | int | 是 | | | token | string | 是 | 客户密钥 | | language| string | 否 | 1.不填,“name”默认返中文;2. 填vi,字段“name” 返越南文;3.填zh_tw,返繁体| 请求url示例 ~~~ /sport/api/v1/players/174040?token=XXXXX ~~~ 返回格式示例 ```json { "id": 636284, //选手id "name": "杰克·斯特恩", //选手名中文 "name_en": "Jack Stern", //选手名英文 "league_id":0, //联赛id "team_id": 3138, //所属队伍id "abbr": "杰克·斯特恩", //选手简称 "logo": " ", //logo "half_logo":"XX.png" //选手半身像 "icon": "", //icon "position": "", //选手位置 备注:足球:擅长位置,F-前锋,M-中场,D-后卫,G-守门员,其他为未知;篮球:C-中锋,SF-小前锋,PF-大前锋,SG-得分后卫,PG-组织后卫,F-前锋,G-后卫,其他为未知 "number": 0, //选手号 "sport_id": 201, //运动id "status": "" //选手状态 "integral":"", //选手评分 "country_id": 0, //所属国家id,篮球无 "update_time": 0, //更新时间 "country_logo": 0, //所属国家logo "age": 0, //选手年龄 "birthday": 0, //选手生日,为0时未知 "height": 0, //选手身高,为0时未知 "weight": 0, //选手体重,为0时未知 "drafted": "", //选秀顺位 "league_career_age": 0, //联盟球龄 "school": "", //毕业学校 "market_value": 1800000, //选手市值 "market_value_currency": "€",//市值单位 "contract_until": "0" //合同截止时间 "preferred_foot": "2" //惯用脚,0-未知,1-左脚,2-右脚,3-左右脚 备注:无值时不显示,篮球无该字段 "ability": [ //能力评分(无值时不显示,篮球无) 1, //能力(无值时不显示),1-扑救,2-预判,3-处理球,4-空中,5-战术,6-进攻,7-防守,8-创造力,9-技术 93, //评分 89 //平均分 ], "advantages": [ //技术优点(无值时不显示,篮球无) [ 15, //类型,类型列表看下面字段解释; 96 //排名 ] ], "disadvantages": [ //技术缺点(无值时不显示,篮球无) [ 17, 497 ] ], "primary_position": "DR", //主要位置(无值时不显示,篮球无),'LW'-左边锋,'RW'-右边锋,'ST'-前锋,'AM'-攻击型中场,'ML'-左中场,'MC'-中路中场,'MR'-右中场,'DM'-防守型中场,'DL'-左后卫,'DC'-中后卫,'DR'-右后卫,'GK'-守门员 "secondary_position": [ //次要位置列表(无值时不显示,篮球无) "MR", "RW", "MC" ], "lang":{ "name_zh_tw":" ", //繁体中文 "name_es":" ", //西班牙语 "name_pt":" ", //葡萄牙语 "name_fr":" ", //法语 "name_de":" ", //德语 "name_sv":" ", //瑞典语 "name_ru":" ", //俄语 "name_uk":" ", //乌克兰语 "name_da":" ", //丹麦语 "name_pl":" ", //波兰语 "name_nl":" ", //荷兰语 "name_ko":" ", //韩语 "name_ms":" ", //马来语 "name_tl":" ", //他加禄语 "name_vi":" ", //越南语 "name_el":" ", //希腊语 "name_tr":" ", //土耳其语 "name_thai":" ", //泰语 "name_ar":" " //阿拉伯语 "name_hi":" " //印度语 }, "transfer": { //转会相关数据 "player_id": 419512, "items": [             { "player_id": 137374, //转会的选手ID "from_team_id": 13022, //来源队伍 "to_team_id": 8927, //目标队伍 "transfer_time": 1735574400, //转会时间 "transfer_fee": 0, //转会金额 "transfer_fee_desc": "", //转会金额描述 "transfer_type": 2, //转会类型 足球:1租借 2租借结束 3转会 4退役 5选秀 6已解约 7已签约;篮球:1-交易,2-签约 "free_agent": 0, //是否是自由球员 "transfer_desc": "" //转会描述             } "teams": [ //转会相关的队伍数据             { "id": 3990, "name": "圣地亚哥漫游者", "name_en": "Santiago Wanderers", "abbr": "漫游者", "logo": "https://img.xxx.png", "icon": "https://img.xxx.png"             } ], "players": [ //转会相关的选手数据             { "id": 209564, "name": "丹尼尔·卡斯特罗", "name_en": "Daniel castro", "abbr": "卡斯特罗", "logo": "https://img.xxx.png", "icon": ""             } ] }, "honor": { "items": [              { "player_id": 35064, "team_id": 5331, "series_id": 10072, "honor_id": 182, "year": "2023"             },             { "player_id": 35064, "team_id": 6180, "series_id": 0, "honor_id": 104, "year": "2023-2024"             }         ], "teams": [ //荣誉相关的队伍数据             { "id": 3990, "name": "圣地亚哥漫游者", "name_en": "Santiago Wanderers", "abbr": "漫游者", "logo": "https://img.xxx.png", "icon": "https://img.xxx.png"             } ], "players": [ //选手相关的队伍数据             { "id": 209564, "name": "丹尼尔·卡斯特罗", "name_en": "Daniel castro", "abbr": "卡斯特罗", "logo": "https://img.xxx.png", "icon": ""             } "series": [ //荣誉相关的赛事数据             { "id": 10072, "name": "英格兰社区盾", "name_en": "Football Association Community Shield", "abbr": "", "logo": "https://img.xxx.png", "icon": "https://img.xxx.png"             } "honors": [ //获得荣誉的具体数据             { "id": 104, "title": "南美超杯冠军", "title_en": "", "logo": "https://img.xxx.png",             } ] } } ``` | 返回参数 | 数据类型 | 描述 | 备注 | | --- | --- | --- | --- | id | int | 选手ID | | | name | string | 选手名称 | | | name_en | string | 选手英文名 | | | team_id | int | 所属球队ID | | | abbr | string | 选手简称 | | | logo | string | 选手头像 | | | half_logo | string | 选手半身像 | | | icon | string | 选手icon | | | position | string | 选手位置 | | | number | int | | 选手号 | | sport_id | int | 所属运动ID | | | status | string | 状态 | | | integral | int | 战斗力 | | | country_id | int | 国家ID | | | update_time | int | 更新时间 | | | country_logo | string | 国家Logo链接 | | | age | int | 年龄 | | | birthday | int | 生日 | | | height | int | 身高 | | | weight | int | 体重 | | | drafted | string | 选秀顺位 | | | league_career_age | int | 联盟球龄 | | | school | string | 毕业学校 | | | market_value | int | 市值 | | | market_value_currency | string | 市值单位 | | | contract_until | int | 合约到期时间 | | | preferred_foot | int | 惯用脚 | | | ability | array of arrays of integers | 能力评分 | | | advantages | array of arrays of integers | 技术优点 | | | disadvantages | array of arrays of integers | 技术缺点 | | | primary_position | string | 主要位置 | | | secondary_position | array of string | 次要位置列表 | | | lang | string | 多语言字段(选手名)| advantages,disadvantages技术类型列表: 1-卸球 2-罚点球 3-任意球 4-远射 5-临门一脚 6-传球 7-组织进攻 8-带球 9-断球 10-铲球 11-稳定性 12-过人 13-长传 14-控球 15-空中对抗 16-地面对抗 17-失误倾向 18-纪律性 19-扑点球 20-反应 21-弃门参与进攻 22-高球拦截 23-处理球 24-远距离射门 25-站位 26-高位紧逼 27-远射扑救 28-传中 29-越位意识 30-近射扑救 31-专注度 32-防守参与度 33-关键传球 34-头球 35-定位球 36-直传球 37-反击 38-一脚出球 39-起高球 40-造犯规 41-内切 42-拳击球 43-解围