This repository has been archived by the owner on May 21, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
API Introduction
Dounx edited this page Apr 5, 2018
·
2 revisions
任天堂商店一共分为三个区域,即美服,欧服,亚服,不同区域返回的数据内容不一样。
三个区域返回游戏数据中,可将GameCode作为外键整合所有信息。
返回的数据中的nsuid用于价格查询。
API | 获取 美服游戏信息 |
---|---|
url | https://nintendo.com/json/content/get/filter/game |
method | POST |
data | JSON Encode |
params |
system: switch 系统类型 sort: title 排序方法 direction: asc 排序方向 shop: ncom 未知 limit: 一次返回的信息数量,最多200 offset: 偏移量
|
返回数据(Json):
category // 分类
slug // 含'-'的游戏标题,可用于合成游戏网页链接
buyitnow // 可否现在购买
release_date // 发售日期
digitaldownload // 是否有数字下载版
free_to_start // 是否有免费试玩
title // 游戏标题
system // 发售平台
id // 可用于合成游戏网页链接
ca_price // 加拿大发售价格
number_of_players // 玩家人数
nsuid // 用于查询各国游戏实时价格
video_link // 视频链接
eshop_price // 美国发售价
front_box_art // 游戏正面盒子封面
game_code // 所有区相同游戏的外键关联
buyonline // 能否在线购买
API | 获取 欧服游戏信息 |
---|---|
url | https://search.nintendo-europe.com/en/select |
method | GET |
params |
fq: type:GAME AND system_type:nintendoswitch* AND product_code_txt:* 查询语句 q: * 选择? sort: sorting_title asc 排序参数 wt: json 返回数据类型 rows: 9999 一次返回的信息数量,无上限 start: 0 偏移量
|
示例: https://search.nintendo-europe.com/en/select?fq=type:GAME AND system_type:nintendoswitch* AND product_code_txt:&q=&sort=sorting_title asc&wt=json&rows=9999&start=0
返回数据(Json):
fs_id
change_date
url // 游戏网页链接
type // 表明是应用还是游戏
club_nintendo
hd_rumble_b
multiplayer_mode // 是否可以多人游戏
pretty_date_s
play_mode_tv_mode_b // 是否可以tv模式
play_mode_handheld_mode_b // 是否可以掌机模式
image_url_sq_s // 图片
pg_s
gift_finder_detail_page_image_url_s // 图片
image_url // 图片
originally_for_t
priority
digital_version_b // 是否有数字版
image_url_h2x1_s // 图片
age_rating_sorting_i
play_mode_tabletop_mode_b // 是否可以桌上模式
publisher
ir_motion_camera_b
excerpt
date_from
price_has_discount_b // 是否打折
gift_finder_description_s
title // 游戏标题
sorting_title // 排序标题
copyright_s // 版权
gift_finder_carousel_image_url_s // 图片
players_to // 玩家人数
gift_finder_wishlist_image_url_s // 图片
pretty_agerating_s // 游戏分级
players_from
age_rating_type
gift_finder_detail_page_store_link_s
price_sorting_f
price_lowest_f
age_rating_value
physical_version_b
game_categories_txt
playable_on_txt
product_code_txt // 所有区相同游戏的外键关联
language_availability // 语言版本
system_type
dates_released_dts // 发售日期
pretty_game_categories_txt
title_extras_txt
nsuid_txt // 用于查询各国游戏实时价格
game_category // 游戏分类
system_names_txt
API | 获取 亚服游戏信息 |
---|---|
url | https://www.nintendo.co.jp/data/software/xml/switch.xml |
method | GET |
返回数据(XML):
initial_code // 所有区相同游戏的外键关联
nsuid // 用于查询各国游戏实时价格
title_name // 游戏标题
maker_name // 制作商
maker_kana // 游戏片假名
price // 日服价格
sales_date // 发售日期
soft_type // 表明是软件还是游戏
platform_id
dl_icon_flg // 是否是dlc
link_url // 游戏网页链接
screenshot_img_flg // 图片
screenshot_img_url // 图片
通过 nsuid 以及国家的两位字母代码查询实时价格信息。
API | 获取各国实时价格信息 |
---|---|
url | https://api.ec.nintendo.com/v1/price |
method | GET |
params |
country: 国家代码,大写 lang: 返回数据语言 ids: nsuid 最多50个
|
示例: https://api.ec.nintendo.com/v1/price?country=US&lang=en&ids=70010000000141
返回数据(Json):
regular_price // 常规价格
----raw_value // 价格数字
----country // 查询的国家
----currency // 货币代码
discount_price // 常规价格
----raw_value // 价格数字
----start_datetime // 打折开始时间
----end_datetime // 打折结束时间
汇率信息是从 api.fixer.io 获取的。
若是想知道哪个国家开了商店服务的话可以直接去查询价格,看是否有返回信息。