CURL.EXE POST XML to Web Server

CURL.EXE POST XML to Web Server

Curl.exe POST XML to Web Server


bat:

@echo %time%
curl.exe -H "Content-Type: text/xml" -X POST --data "<methodCall><methodName>sycgsti.launcher</methodName><params><param><value><string>amFzaGxpYW8=</string></value></param></params></methodCall>" "http://127.0.0.1:24414/syris" --output data.xml
@echo %time%
pause


結果:

<?xml version="1.0" encoding="UTF-8"?>
<methodResponse>
<params>
<param><value><array><data>
<value><string>OK</string></value>
<value><string>DA7921811431685FABE2A399FD465F8F</string></value>
<value><string>lkYBJXfZj7kmrDDsF3uqkzsc7+Zgtkl/YU82XvvXsFyBtOZwIOFeP4d1ECnqLKkcf5Xh0NpKxidOTUzgD//DZGPFLtMXJGxujjNRkfxL6/wcB0HEPYvJxMOcMgmGMtlhFbnEejeeKqXdy/wYlUdWGKsSW1+m2SxJbtEffqfUzVTXufqunqP1IaHSm6QloGa6pa18Swtyti1zvOMkeL+wNGQOcrInOQnxeBg2fbzHZwwakpQtgmdQTrnstbTtpchIYQh4IXSzy0h47gtgjn48UmFkAJtTlY5phlL8LAloSTwkUdMZtJjVBu0bn5AAVV7AGl3BqYYjngn+goAG4ef/W+dYgmdaKVFqUGPDHZixmzUw64xfmeFWMMkOrm8NBOzNeHyf0eDYaX4gvGBIPuVGOg5RuARk3S7/6nvm/EMbS7wOMUXmWM0QtMhbMCtxEBgKPSpCvSTty4kZ2ZW7YY6GWLFdDm0eUB2/XFNI3PgGCpQZmEPRDgppUKiPUAefLXcthubrRTTexJJuyBfF7s2sKvOAZJYIlBP5OSsHAaWWNJQ9pZdGqlndokunYrazvApp6cyRr3icp5Lf6oxkzVV1jjb3An38Jwebd4Ai7YRPDXcQLm6DFt6SrcIysl0BXUzRDK8iay9rEc1vOQVcBZJhZxAPArjrknRhVTOF5BPraz8=</string></value>
<value><string>LAnDFyzYC9z0fm6NxMP/TlDfiHHXvfU/kwZXCbqeqSKAIWjea84zgYmA9KwDsNL9w1IdGnKFlv3Qg53MxGjLEs1yEXIpwBrc/N6XV8aVsUjK+0KHxMmiY/7i8AmStHbERdfdz5BLo712ZR3IpE1e/wvoqYjtHE3ggGUNEX6k0tf6AvOo64jvLYVZJdNqw1cVhXIaVoWrHhSj4ABqi+9SsMdua6ghH1e3GPOi7cOVLzn+5H+Eizki7ZxSUilUI/7nIIw2711zDouawlG052U3vyU2rO8DXmr3qsws/Ys1/pWS3+woMrzfZxYZlhzdCLAWw0V5VrcbkMhmhN6NybXj3Xu6yd7BVUf9obb882x0zuglYbhujSjTAX2yJQYV+T4G9uKyRQUP7TA/Kse0z7mBQhzxYULj2M40W4Tt1d8H6Y/XBHZmcER3ojko9nnpqC3IsgFWUJL6C+HmJ8ESYKse8dEv3tfB+ba5RxKYmEGio+r4xLA70gWwCRN1zsh+qTUf+WerHgFkUT1uXNrvhfntkTPZwHd0nZ0xGpenkfq4y8FM2aridZayu14P+5AFSLnaKA9qHZuLzapQlc1c8fHY78MX1JUkf5eu8pTK3NhMWPzoQTWx+FttH/pXtITw9G4thMtF8YRiNRxfPassF0aQ0YMeF0/cQ1zO9zmTSIfkpNg=</string></value>
</data></array></value></param>
</params>
</methodResponse>	

PS.

POSTMAN 測試:

http://127.0.0.1:24414/syris [XML]

<?xml version="1.0" encoding="UTF-8"?>
<methodCall>
		<methodName>sycgsti.launcher</methodName>
		<params>
				<param>
						<value>
								<string>amFzaGxpYW8=</string>
						</value>
				</param>
		</params>
</methodCall>

One thought on “CURL.EXE POST XML to Web Server

發表迴響

你的電子郵件位址並不會被公開。 必要欄位標記為 *