### Configuration Examples Source: https://zmusic.zhenxin.me/netease-api Examples demonstrating how to configure the Netease Cloud Music API link in different application versions (V4 and V2). ```APIDOC ## Configuration ### V4 Configuration ``` # API Settings [api] # Netease Cloud Music nετεase-link = "https://ncm.zhenxin.me" ``` ### V2 Configuration ``` /// API Settings "api": { /// Netease Cloud Music API Address /// /// Uses the open-source project NeteaseCloudMusicApi /// Recommended to self-deploy, requires Node.js environment /// Address: https://github.com/Binaryify/NeteaseCloudMusicApi "netease": "https://ncm.zhenxin.me" }, ``` ``` -------------------------------- ### Deployment Instructions Source: https://zmusic.zhenxin.me/netease-api Step-by-step guide on how to deploy the Netease Cloud Music API, including prerequisites, code acquisition, dependency installation, and running the application. ```APIDOC ## Deployment Ensure you have the following environments installed before deployment: * Git * Node.js ### 1. Get the Code ```bash # Download the tarball wget https://registry.npmmirror.com/NeteaseCloudMusicApi/-/NeteaseCloudMusicApi-4.27.0.tgz # Extract the tarball tar -xzvf NeteaseCloudMusicApi-4.27.0.tgz # Move to a new directory mv package NeteaseCloudMusicApi # Navigate into the directory cd NeteaseCloudMusicApi ``` ### 2. Install Dependencies ```bash npm install ``` ### 3. Run the Application ```bash node app.js ``` ### 4. Custom Port #### 4.1 Linux ```bash PORT=4000 node app.js ``` #### 4.2 Windows ```cmd set PORT=4000 && node app.js ``` ``` -------------------------------- ### TOML Configuration for ZMusic Source: https://zmusic.zhenxin.me/guide/config This TOML configuration file defines various settings for the ZMusic application. It includes options for enabling/disabling debug mode, checking for updates, setting the language, defining message prefixes, configuring API endpoints, managing VIP authorization (QQ and key), and setting up proxy server details (enable, type, hostname, port). ```toml # 是否开启调试模式 debug = false # 是否检查更新 check-update = true # 插件使用的语言 # 支持的语言: # auto: 自动检测 (默认) # en-US: English # zh-CN: 简体中文 language = "auto" # 消息前缀 prefix = "&bZMusic &e>>> &r" # API设置 [api] # 网易云音乐 netease-link = "https://ncm.zhenxin.me" # ZMusic VIP设置 [vip] # 授权QQ qq = "" # 授权Key key = "" # 代理设置 [proxy] # 是否启用代理 enable = false # 代理类型 HTTP/SOCKS type = "HTTP" # 主机名 hostname = "127.0.0.1" # 端口 port = 8080 ``` -------------------------------- ### 部署NeteaseCloudMusicApi (Linux) Source: https://zmusic.zhenxin.me/netease-api 这组命令展示了在Linux环境下部署NeteaseCloudMusicApi的过程。它包括下载tgz包、解压、进入目录、安装依赖和运行应用。 ```bash wget https://registry.npmmirror.com/NeteaseCloudMusicApi/-/NeteaseCloudMusicApi-4.27.0.tgz tar -xzvf NeteaseCloudMusicApi-4.27.0.tgz mv package NeteaseCloudMusicApi cd NeteaseCloudMusicApi npm install node app.js ``` -------------------------------- ### 自定义NeteaseCloudMusicApi端口 (Linux) Source: https://zmusic.zhenxin.me/netease-api 此命令演示了如何在Linux系统上运行NeteaseCloudMusicApi并指定自定义端口。通过设置PORT环境变量,可以使API监听在指定的端口上。 ```bash PORT=4000 node app.js ``` -------------------------------- ### 自定义NeteaseCloudMusicApi端口 (Windows) Source: https://zmusic.zhenxin.me/netease-api 此命令演示了如何在Windows系统上运行NeteaseCloudMusicApi并指定自定义端口。通过使用`set`命令设置PORT环境变量,可以使API监听在指定的端口上。 ```cmd set PORT=4000 && node app.js ``` -------------------------------- ### Public API Servers Source: https://zmusic.zhenxin.me/netease-api List of public Netease Cloud Music API server endpoints, their locations, providers, and versions. Use with caution, especially for login operations. ```APIDOC ## Public API Servers **Note:** Please use public servers with caution for login operations. The provider is not responsible for any issues such as account theft resulting from the use of public servers. | API Address | Location | Provider | Version | |---------------------|----------|--------------|---------| | https://ncm.zhenxin.me | Shanghai | Zhenxin | | | https://zm.i9mr.com | Yangzhou | Moyun Cloud | | | https://music.mcseekeri.com | USA | MCSeekeri | | | https://zm.wwoyun.cn | Ningbo | Lanqin | | ``` -------------------------------- ### 配置网易云音乐API (V4) Source: https://zmusic.zhenxin.me/netease-api 此代码片段展示了如何在V4配置中设置网易云音乐API的链接。它是一个简单的INI格式配置,用于指定API的URL。 ```ini [api] # 网易云音乐 netease-link = "https://ncm.zhenxin.me" ``` -------------------------------- ### 配置网易云音乐API (V2) Source: https://zmusic.zhenxin.me/netease-api 此代码片段展示了如何在V2配置中设置网易云音乐API的地址。它使用了JSON格式,并提供了API地址的键值对,同时附带了关于使用NeteaseCloudMusicApi项目的说明。 ```json /// API设置 "api": { /// 网易云音乐API地址 /// /// 使用开源项目NeteaseCloudMusicApi /// 推荐自行部署,需Node.js环境 /// 地址: https://github.com/Binaryify/NeteaseCloudMusicApi "netease": "https://ncm.zhenxin.me" }, ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.