Linux 环境接口测试命令
Linux 环境接口测试命令是指在 CentOS 操作系统中使用的命令,以便测试和验证 Linux 环境中的接口是否正常工作。这些命令通常使用 curl 工具来发送 HTTP 请求到指定的 URL,以获取或提交数据。
一、curl 命令简介
curl 命令是一个常用的命令行工具,用于传输数据指定的 URL。它支持多种协议,包括 HTTP、HTTPS、FTP 等。curl 命令可以用来发送 GET、POST、PUT、DELETE 等请求,并可以指定请求头、请求体和查询参数等。
二、接口测试命令
1. 获取 hospitalized 签名接口
curl 命令:curl http://192.168.117.0:5000/eqcs/structure/getHospitalizedSignature-XPOST-d '{"docContent":"ܴuwhjdaosjdaiosjdoǿ˴waldҼӰӰӰӹǺǰؿƵİڵǼisolkadop"}' --header "Content-Type:application/json;charset=UTF-8"
该命令用于获取 hospitalized 签名接口,发送 POST 请求到指定的 URL,请求体中包含了 docContent 的 JSON 数据。
2. Nomallizer 接口
curl 命令:curl http://192.168.117.0:5000/eqcs/structure/Nomallizer-XPOST-d '{"dis_history":"Ѫѹ","dis_admin":"Ѫѹ"}' --header "Content-Type:application/json;charset=UTF-8"
该命令用于 Nomallizer 接口,发送 POST 请求到指定的 URL,请求体中包含了 dis_history 和 dis_admin 的 JSON 数据。
3. Nomallizer 接口(第二个)
curl 命令:curl http://192.168.117.0:5000/eqcs/structure/Nomallizer-XPOST-d '{"diseaseName":"ѪѹѪѹ"}' --header "Content-Type:application/json;charset=UTF-8"
该命令用于 Nomallizer 接口,发送 POST 请求到指定的 URL,请求体中包含了 diseaseName 的 JSON 数据。
4. 获取 Patient Info 接口
curl 命令:curl http://192.168.117.0:5000/eqcs/structure/getPatientInfo-XPOST-d '{"docContent":"ܴuwhjdaosjdaiosjdoǿ˴waldҼӰӰӰӹǺǰؿƵİڵǼisolkadop"}' --header "Content-Type:application/json;charset=UTF-8"
该命令用于获取 Patient Info 接口,发送 POST 请求到指定的 URL,请求体中包含了 docContent 的 JSON 数据。
5. 相似记录接口
curl 命令:curl http://192.168.117.0:5000/eqcs/structure/SimilarRecords-XPOST-d '{"sentence":"gaoxueya","data":["1","2"],"score":"0.96"}' --header "Content-Type:application/json;charset=UTF-8"
该命令用于相似记录接口,发送 POST 请求到指定的 URL,请求体中包含了 sentence、data 和 score 的 JSON 数据。
6. 获取 Record Time 接口
curl 命令:curl http://192.168.117.0:5000/eqcs/structure/getRecordTime-XPOST-d '{"docContent":"uwhjdaosjdaiosjdoǿ˴waldҼӰӰӰӹǺǰؿƵİڵǼi"' --header "Content-Type:application/json;charset=UTF-8"
该命令用于获取 Record Time 接口,发送 POST 请求到指定的 URL,请求体中包含了 docContent 的 JSON 数据。
这些命令都是用于测试 Linux 环境中的接口是否正常工作的命令,都是使用 curl 工具发送 HTTP 请求到指定的 URL,以获取或提交数据。