curlRequest\json\createtodo.json
{
"name": "eat",
"status": 0,
"remark": "eat apple"
}
curlRequest\json\createtodo2.json
{
"name": "eat",
"status": 0,
"remark": "eat orange"
}
curlRequest\json\dddlogin.json
curlRequest\json\login.json
curlRequest\json\loginldap.json
curlRequest\json\post.json
{
"title": "书籍标题",
"body": "bar",
"userId": 1
}
curlRequest\json\post2.json
{
"name": "wash face",
"status": 0,
"remark": "before out"
}
curlRequest\json\updatetodo.json
{
"name": "eat",
"status": 0,
"remark": "eat 30 apple"
}
curlRequest\ddd_req.sh
curlRequest\req_b2b.bat
@REM 通过zfdhd 获取order
@REM curl -s "http://localhost:5121/api/Orders/zfhtzdh/GCFH0000000000000592"
@REM 通过order id获取order process
@REM curl -s "http://localhost:5121/api/Processes/orderid/2"
curlRequest\req_ddd.bat
@REM -----------------------------------------------------------------------------------------------------------
@REM curl "http://localhost:5294/api/Auths/login" ^
@REM -H "Accept-Language: zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6" ^
@REM -H "Connection: keep-alive" ^
@REM -H "Content-Type: application/json-patch+json" ^
@REM -H ^"Cookie: authorized-token=^{^%^22accessToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.admin^%^22^%^2C^%^22expires^%^22:1919520000000^%^2C^%^22refreshToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.adminRefresh^%^22^}; multiple-tabs=true; .AspNetCore.Antiforgery.s4870XLI5gU=CfDJ8Axlvo0Ayg1JuTT9Rad2NjbWiNeFXrOQ3p46CBdIPwXxhO5mWgxcRkIJiLn28rVCgNYTqlWHKPDGhkppyXI9a2zJmIT40_tNOnUrDdnAFug48IfZfpeSIp7onWOItGu2AO90pK34CAhXjPEdXJd20VE^" ^
@REM -H "Origin: http://localhost:5294" ^
@REM -H "Referer: http://localhost:5294/swagger/index.html" ^
@REM -H "Sec-Fetch-Dest: empty" ^
@REM -H "Sec-Fetch-Mode: cors" ^
@REM -H "Sec-Fetch-Site: same-origin" ^
@REM -H "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0" ^
@REM -H "accept: */*" ^
@REM -H ^"sec-ch-ua: ^\^"Not/A)Brand^\^";v=^\^"8^\^", ^\^"Chromium^\^";v=^\^"126^\^", ^\^"Microsoft Edge^\^";v=^\^"126^\^"^" ^
@REM -H "sec-ch-ua-mobile: ?0" ^
@REM -H ^"sec-ch-ua-platform: ^\^"Windows^\^"^" ^
@REM --data-raw ^"^{^
@REM ^\^"userName^\^": ^\^"admin^\^",^
@REM ^\^"password^\^": ^\^"Abc123^@^\^"^
@REM ^}^"
@REM -----------------------------------------------------------------------------------------------------------
@REM post请求,读取外本json,普通登录
@REM curl -X POST http://localhost:5121/api/Auths/login -H "Content-Type: application/json" -d @login.json
@REM -----------------------------------------------------------------------------------------------------------
@REM ldap登录
@REM curl -X POST https://localhost:7244/api/Auths/login/ldap -H "Content-Type: application/json" -d @loginldap.json
@REM -----------------------------------------------------------------------------------------------------------
@REM post请求,读取外本json,普通登录
@REM curl -s -X POST https://localhost:7244/api/Auths/login -H "Content-Type: application/json" -d @login.json
@REM -----------------------------------------------------------------------------------------------------------
@REM curl "http://localhost:5121/api/Accounts" ^
@REM -H "Accept-Language: zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6" ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiY2ltYWRtaW4iLCJleHAiOjE3MjM5NzExODQsImlzcyI6Ikxvbmdmb3JjZSIsImF1ZCI6IkdpZ2FEZXZpY2UifQ.oUT3gZVo92drwXQZOFs1eaVqdCRwlN4BJHJ9qsppod0" ^
@REM -H "Connection: keep-alive" ^
@REM -H ^"Cookie: authorized-token=^{^%^22accessToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.admin^%^22^%^2C^%^22expires^%^22:1919520000000^%^2C^%^22refreshToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.adminRefresh^%^22^}; multiple-tabs=true; .AspNetCore.Antiforgery.s4870XLI5gU=CfDJ8Axlvo0Ayg1JuTT9Rad2NjbWiNeFXrOQ3p46CBdIPwXxhO5mWgxcRkIJiLn28rVCgNYTqlWHKPDGhkppyXI9a2zJmIT40_tNOnUrDdnAFug48IfZfpeSIp7onWOItGu2AO90pK34CAhXjPEdXJd20VE; .AspNetCore.Identity.Application=CfDJ8Axlvo0Ayg1JuTT9Rad2NjbEzeah-u9d3G8CION5NonTDX5tSZ2wPUO0oDGhdCiKC2SH4WooB4h8ZX4jdEcQ00YvjAYS342dBAtJ3i_IAqKQYb2B2I9t3VrziWAcCc3w-C8546aW3dLwQavAFD3wDmw5klnOdlYrkSr8AIfSowkvpM-SdpAZfkx3NTcsmok1up4CTIflUUNRmsGyPrAbMotd4rb_7IJy0KOp8R32OOeIS8jNS-r3N4QheJrNPLn4kjD_BsN5bEJAm3NpHqU3qE6mXVWx_MNt8HJMyQo6n9hNJe4p6HE38N4oyoykz9nSXQcG6CVXhF3Xqo6wwlhq99IDTlT0Q_ecFnexBgCyWQk7sCiqVNEO1B3I1rABr9gcB5pPxn_95DQHT6r6-huo6ir4_D6YrjBPACecIg-dbHRAH7XgR15nP32hP5BXDtOG3JtmZocDeQbK_vH0DQe_KVgSSKdIALS-cwlPUzvYXS4iZQyoVsqwftjx_CWXBt45txIELAfZpdduX6P1DYTN-2Vf5MJ6CYhgb9vheIcQwn5Zlmz8KahUm2h3M8SiS7FLZMfdQ-l7dTwDuJvz8oO0f2OSHmnGm1MU8o3mBwsNW6K4iv6ED4keJs--YZ8bq-Kj6g^" ^
@REM -H "Referer: http://localhost:5121/swagger/index.html" ^
@REM -H "Sec-Fetch-Dest: empty" ^
@REM -H "Sec-Fetch-Mode: cors" ^
@REM -H "Sec-Fetch-Site: same-origin" ^
@REM -H "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0" ^
@REM -H "accept: */*" ^
@REM -H ^"sec-ch-ua: ^\^"Not/A)Brand^\^";v=^\^"8^\^", ^\^"Chromium^\^";v=^\^"126^\^", ^\^"Microsoft Edge^\^";v=^\^"126^\^"^" ^
@REM -H "sec-ch-ua-mobile: ?0" ^
@REM -H ^"sec-ch-ua-platform: ^\^"Windows^\^"^"
@REM -----------------------------------------------------------------------------------------------------------
@REM curl -s -X GET http://localhost:5121/api/Accounts ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiY2ltYWRtaW4iLCJleHAiOjE3MjM5NzExODQsImlzcyI6Ikxvbmdmb3JjZSIsImF1ZCI6IkdpZ2FEZXZpY2UifQ.oUT3gZVo92drwXQZOFs1eaVqdCRwlN4BJHJ9qsppod0"
curl -s -X GET http://localhost:5121/api/Accounts ^
-H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiWjA1NzM1IiwiZXhwIjoxNzIzOTcxOTgxLCJpc3MiOiJMb25nZm9yY2UiLCJhdWQiOiJHaWdhRGV2aWNlIn0.bh03h4c3ovGJbFV1d3LXF0uInQmMKTTOCZXF8_98HKA"
curlRequest\req_ddd01.bat
@REM -----------------------------------------------------------------------------------------------------------
@REM curl "http://localhost:5294/api/Auths/login" ^
@REM -H "Accept-Language: zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6" ^
@REM -H "Connection: keep-alive" ^
@REM -H "Content-Type: application/json-patch+json" ^
@REM -H ^"Cookie: authorized-token=^{^%^22accessToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.admin^%^22^%^2C^%^22expires^%^22:1919520000000^%^2C^%^22refreshToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.adminRefresh^%^22^}; multiple-tabs=true; .AspNetCore.Antiforgery.s4870XLI5gU=CfDJ8Axlvo0Ayg1JuTT9Rad2NjbWiNeFXrOQ3p46CBdIPwXxhO5mWgxcRkIJiLn28rVCgNYTqlWHKPDGhkppyXI9a2zJmIT40_tNOnUrDdnAFug48IfZfpeSIp7onWOItGu2AO90pK34CAhXjPEdXJd20VE^" ^
@REM -H "Origin: http://localhost:5294" ^
@REM -H "Referer: http://localhost:5294/swagger/index.html" ^
@REM -H "Sec-Fetch-Dest: empty" ^
@REM -H "Sec-Fetch-Mode: cors" ^
@REM -H "Sec-Fetch-Site: same-origin" ^
@REM -H "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0" ^
@REM -H "accept: */*" ^
@REM -H ^"sec-ch-ua: ^\^"Not/A)Brand^\^";v=^\^"8^\^", ^\^"Chromium^\^";v=^\^"126^\^", ^\^"Microsoft Edge^\^";v=^\^"126^\^"^" ^
@REM -H "sec-ch-ua-mobile: ?0" ^
@REM -H ^"sec-ch-ua-platform: ^\^"Windows^\^"^" ^
@REM --data-raw ^"^{^
@REM ^\^"userName^\^": ^\^"admin^\^",^
@REM ^\^"password^\^": ^\^"Abc123^@^\^"^
@REM ^}^"
@REM -----------------------------------------------------------------------------------------------------------
@REM post请求,读取外本json,普通登录
@REM curl -X POST http://localhost:5121/api/Auths/login -H "Content-Type: application/json" -d @login.json
@REM -----------------------------------------------------------------------------------------------------------
@REM ldap登录
@REM curl -X POST https://localhost:7244/api/Auths/login/ldap -H "Content-Type: application/json" -d @loginldap.json
@REM -----------------------------------------------------------------------------------------------------------
@REM post请求,读取外本json,普通登录
@REM curl -s -X POST https://localhost:7244/api/Auths/login -H "Content-Type: application/json" -d @dddlogin.json
@REM -----------------------------------------------------------------------------------------------------------
@REM curl "http://localhost:5121/api/Accounts" ^
@REM -H "Accept-Language: zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6" ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiY2ltYWRtaW4iLCJleHAiOjE3MjM5NzExODQsImlzcyI6Ikxvbmdmb3JjZSIsImF1ZCI6IkdpZ2FEZXZpY2UifQ.oUT3gZVo92drwXQZOFs1eaVqdCRwlN4BJHJ9qsppod0" ^
@REM -H "Connection: keep-alive" ^
@REM -H ^"Cookie: authorized-token=^{^%^22accessToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.admin^%^22^%^2C^%^22expires^%^22:1919520000000^%^2C^%^22refreshToken^%^22:^%^22eyJhbGciOiJIUzUxMiJ9.adminRefresh^%^22^}; multiple-tabs=true; .AspNetCore.Antiforgery.s4870XLI5gU=CfDJ8Axlvo0Ayg1JuTT9Rad2NjbWiNeFXrOQ3p46CBdIPwXxhO5mWgxcRkIJiLn28rVCgNYTqlWHKPDGhkppyXI9a2zJmIT40_tNOnUrDdnAFug48IfZfpeSIp7onWOItGu2AO90pK34CAhXjPEdXJd20VE; .AspNetCore.Identity.Application=CfDJ8Axlvo0Ayg1JuTT9Rad2NjbEzeah-u9d3G8CION5NonTDX5tSZ2wPUO0oDGhdCiKC2SH4WooB4h8ZX4jdEcQ00YvjAYS342dBAtJ3i_IAqKQYb2B2I9t3VrziWAcCc3w-C8546aW3dLwQavAFD3wDmw5klnOdlYrkSr8AIfSowkvpM-SdpAZfkx3NTcsmok1up4CTIflUUNRmsGyPrAbMotd4rb_7IJy0KOp8R32OOeIS8jNS-r3N4QheJrNPLn4kjD_BsN5bEJAm3NpHqU3qE6mXVWx_MNt8HJMyQo6n9hNJe4p6HE38N4oyoykz9nSXQcG6CVXhF3Xqo6wwlhq99IDTlT0Q_ecFnexBgCyWQk7sCiqVNEO1B3I1rABr9gcB5pPxn_95DQHT6r6-huo6ir4_D6YrjBPACecIg-dbHRAH7XgR15nP32hP5BXDtOG3JtmZocDeQbK_vH0DQe_KVgSSKdIALS-cwlPUzvYXS4iZQyoVsqwftjx_CWXBt45txIELAfZpdduX6P1DYTN-2Vf5MJ6CYhgb9vheIcQwn5Zlmz8KahUm2h3M8SiS7FLZMfdQ-l7dTwDuJvz8oO0f2OSHmnGm1MU8o3mBwsNW6K4iv6ED4keJs--YZ8bq-Kj6g^" ^
@REM -H "Referer: http://localhost:5121/swagger/index.html" ^
@REM -H "Sec-Fetch-Dest: empty" ^
@REM -H "Sec-Fetch-Mode: cors" ^
@REM -H "Sec-Fetch-Site: same-origin" ^
@REM -H "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0" ^
@REM -H "accept: */*" ^
@REM -H ^"sec-ch-ua: ^\^"Not/A)Brand^\^";v=^\^"8^\^", ^\^"Chromium^\^";v=^\^"126^\^", ^\^"Microsoft Edge^\^";v=^\^"126^\^"^" ^
@REM -H "sec-ch-ua-mobile: ?0" ^
@REM -H ^"sec-ch-ua-platform: ^\^"Windows^\^"^"
@REM -----------------------------------------------------------------------------------------------------------
@REM curl -s -X GET http://localhost:5121/api/Accounts ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiY2ltYWRtaW4iLCJleHAiOjE3MjM5NzExODQsImlzcyI6Ikxvbmdmb3JjZSIsImF1ZCI6IkdpZ2FEZXZpY2UifQ.oUT3gZVo92drwXQZOFs1eaVqdCRwlN4BJHJ9qsppod0"
@REM curl -s -X GET http://localhost:5121/api/Accounts ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiWjA1NzM1IiwiZXhwIjoxNzIzOTcxOTgxLCJpc3MiOiJMb25nZm9yY2UiLCJhdWQiOiJHaWdhRGV2aWNlIn0.bh03h4c3ovGJbFV1d3LXF0uInQmMKTTOCZXF8_98HKA"
@REM -----------------------------------------------------------------------------------------------------------
@REM post请求,读取外本json,普通登录
@REM curl -X POST http://localhost:5294/api/Auths/login -H "Content-Type: application/json" -d @dddlogin.json
@REM --------------------------------
@REM 获取个人信息
@REM curl -s -X GET http://localhost:5294/api/Accounts ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiJhM2Q3NTQ4Mi1jYmQ2LTRkYTMtOTk1Zi1jZGE4YmI4YTI5ZDkiLCJleHAiOjE3MjM4MTA3ODgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.8KGrsXKOakZ7QSqpeeRqcs-qXkfLDcfafsd0ao5g6Eo"
@REM --------------------------------
@REM curl -X POST http://localhost:5294/api/Todos ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8" ^
@REM -H "Content-Type: application/json-patch+json" ^
@REM -d @createtodo2.json
@REM curl -X GET http://localhost:5294/api/Users?UserName=admin ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8"
@REM curl -X GET http://localhost:5294/api/Todos?PrePage=10 ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8"
@REM 4dd26f18-d750-4846-ba3b-c8b43a25d10e
@REM curl -X GET http://localhost:5294/api/Todos/e3dcc7ab-47d4-4b9a-49a9-08dcbe9384d6 ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8"
@REM
@REM curl -X GET http://localhost:5294/api/Todos/67493325-6e99-4d06-fd9f-08dcbe7e2036 ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8"
@REM curl -X GET http://localhost:5294/api/Todos/67493325-6e99-4d06-fd9f-08dcbe7e2036 ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8"
@REM curl -X PUT http://localhost:5294/api/Todos/67493325-6e99-4d06-fd9f-08dcbe7e2036 ^
@REM -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8"
@REM -d @updatetodo.json
@REM curl -X 'PUT' \
@REM 'http://localhost:5294/api/Todos/67493325-6e99-4d06-fd9f-08dcbe7e2036' \
@REM -H 'accept: */*' \
@REM -H 'Content-Type: application/json-patch+json' \
@REM -d '{
@REM "name": "eat",
@REM "status": 0,
@REM "remark": "eat 10 apple"
@REM }
@REM '
@REM curl -X PUT http://localhost:5294/api/Todos/67493325-6e99-4d06-fd9f-08dcbe7e2036 ^
@REM -H "Content-Type: application/json-patch+json" ^
@REM -d @updatetodo.json
curl -X GET http://localhost:5294/api/Todos/67493325-6e99-4d06-fd9f-08dcbe7e2036 ^
-H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiI0ZGQyNmYxOC1kNzUwLTQ4NDYtYmEzYi1jOGI0M2EyNWQxMGUiLCJleHAiOjE3MjM5NTkxNzgsImlzcyI6IkVsZXRyaWNBUEkiLCJhdWQiOiJFbGV0cmljQVBJIn0.SOx8HqbEsV73DWz-4L__BZ4hmMY20YQ7sUEpO9KI-i8"
curlRequest\req_lean.bat
@REM get 请求
@REM curl -s https://jsonplaceholder.typicode.com/posts/1
@REM post 请求
curl -s -d '@post.json' https://jsonplaceholder.typicode.com/posts
curl "https://www.cnblogs.com/zhuoss/ajax/PostComment/Add.aspx" ^
-H "accept: application/json, text/javascript, */*; q=0.01" ^
-H "accept-language: zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6" ^
-H "content-type: application/json; charset=UTF-8" ^
-H ^"cookie: _ga=GA1.1.920207567.1717286811; _ga_M95P3TTWJZ=deleted; _ga_M95P3TTWJZ=deleted; _clck=1slxzl8^%^7C2^%^7Cfmx^%^7C0^%^7C1625; _ga_3Q0DVSGN10=GS1.1.1720009122.3.1.1720009128.54.0.0; HMACCOUNT=B2EC4F03AFDAAF8D; .AspNetCore.Antiforgery.b8-pDmTq1XM=CfDJ8ONv0caE5GtEh3YJ5j088kn41EEeQP_wuad4pG2kpJi4KlTSt495rBLhqKlUN3i3HxgrEY7lPZCfSZ1f29mzfJ1KHe0rb-Plx3aLfbxv5eVboGaHYS1GxGc2kuf8S3rnf9bPPDdsUvIo0gpl7SMVz7Q; __utma=226521935.920207567.1717286811.1721137299.1721137299.1; __utmc=226521935; __utmz=226521935.1721137299.1.1.utmcsr=zzk.cnblogs.com^|utmccn=(referral)^|utmcmd=referral^|utmcct=/; _ga_XPE8C2TMTE=GS1.1.1721137536.1.1.1721137586.0.0.0; Hm_lvt_866c9be12d4a814454792b1fd0fed295=1722855798; _ga_C2LFP3RFGH=GS1.1.1723040311.25.1.1723040315.0.0.0; .Cnblogs.AspNetCore.Cookies=CfDJ8ONv0caE5GtEh3YJ5j088kkyj_PpE5VLWAzATXGiSwvEsSyj7G9UjaDzrKoAf8F-qEWp6QVcIOSb4ltz4m6cgEeG-TXJyafqh8Fk8C_4hdeKt0eJcMcINSKd1oqx8ToSsknYwrrJMw0CKDP9gU2wYBfPplVLL7KPXH-uQhhOcz2IsnLbU6TQ_DGdwiidVyK5ARwPfxsyRbdfLRoBa95Zr3TFxKXJfeMt526dY9eXGzdWZ57ZDxeXUmatQp63A9DUX631SnCjvoZ1jVsh1Vv944oeEPbXOQGVzC2LpbjK2_WceQKISLB-W4P5_fWuhuHSLgpg9Nn3c9swb-k6PHYSn45xqeX0TyAHdlFSktpOcGmikguNxTO8EM_zEYTVKI5NYaxl9qHa7V6YKNPI_dje2QnJbIaukPKTTwv0Pge3h0j7eK6nQRVGINLJDBv59lEj-25SZukCY78SmjZDhhr0h-gVBsIS2Qj5ZnyRghTOcB7_ZCA9ZAKHvLBvHSTitykOv04_g6ZKPATEoAicgeSif0d1OQfgcN6cQha-cOmHqKz9nLM7PblpGa7rH5qfmzXlyx2mgtCNDuB8FXEbb8czXEo; _ga_L4KFJNGL7P=GS1.1.1723295219.5.1.1723295844.0.0.0; _ga_M95P3TTWJZ=GS1.1.1723474560.74.1.1723474563.0.0.0; Hm_lpvt_866c9be12d4a814454792b1fd0fed295=1723474564^" ^
-H "origin: https://www.cnblogs.com" ^
-H "priority: u=1, i" ^
-H "referer: https://www.cnblogs.com/zhuoss/p/18353191" ^
-H "requestverificationtoken: CfDJ8ONv0caE5GtEh3YJ5j088km5eV16fClwmCdb8l7b6y14Ygk8qZ3VxNRkSHXxBuiYFX2SBn1pkwDXfr_p20OBUTZJDH7OD6nMuwhyAKhWRXdpFyI49627niAqgy4bNbvra4tUbM58GnGAQJYL4xodz5V08tpNxe32X3biniyjDfbQnoauUNF3o321EC5nWvSA0Q" ^
-H ^"sec-ch-ua: ^\^"Not/A)Brand^\^";v=^\^"8^\^", ^\^"Chromium^\^";v=^\^"126^\^", ^\^"Microsoft Edge^\^";v=^\^"126^\^"^" ^
-H "sec-ch-ua-mobile: ?0" ^
-H ^"sec-ch-ua-platform: ^\^"Windows^\^"^" ^
-H "sec-fetch-dest: empty" ^
-H "sec-fetch-mode: cors" ^
-H "sec-fetch-site: same-origin" ^
-H "user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0" ^
-H "x-requested-with: XMLHttpRequest" ^
--data-raw ^"^{^\^"postId^\^":18353191,^\^"body^\^":^\^"test^\^",^\^"parentCommentId^\^":0^}^"
curl -X POST http://localhost:8080/api -H "Content-Type: application/json" -d @sendfile.json
curlRequest\run.bat
@echo off
setlocal enabledelayedexpansion
chcp 65001
rem 设置一个变量用于存储最新的文件名和修改时间
set newestFile=
set newestTime=0
rem 遍历当前目录下所有以temp开头的文件
for /f "delims=" %%i in ('dir /b /a-d req*.bat') do (
set "currentFile=%%~fi"
set "currentTime=%%~ti"
rem 提取时间中的小时、分钟和秒
for /f "tokens=1-3 delims=:." %%j in ("%currentTime%") do (
set /a currentHour=%%j, currentMinute=%%k, currentSecond=%%l
)
rem 将时间转换为可比较的数字格式
set /a currentTime=!currentHour! * 3600 + !currentMinute! * 60 + !currentSecond!
rem 如果当前文件的时间比已知的最新文件的时间新,则更新最新文件信息
if !currentTime! gtr !newestTime! (
set newestFile=%%~fi
set newestTime=!currentTime!
)
)
set file_path=!newestFile!
for %%F in ("%file_path%") do set "file_name=%%~nF"
set out_file_path=%file_name%_out.md
for /f "tokens=2 delims==" %%a in ('wmic os get localdatetime /value') do set "dt=%%a"
set "formatted_time=%dt:~0,4%%dt:~4,2%%dt:~6,2%_%dt:~8,2%%dt:~10,2%%dt:~12,2%"
echo. >> %out_file_path%
echo. >> %out_file_path%
echo # %formatted_time%_%file_name% >> %out_file_path%
echo. >> %out_file_path%
echo ```json >> %out_file_path%
call %file_path% >> %out_file_path%
echo. >> %out_file_path%
echo ``` >> %out_file_path%
code %out_file_path%
curlRequest\run_sh.sh
curlRequest\zz.bat
set "scriptPath=%cd%"
D: && cd D:\dotnet.-script\App\bin\Debug\net8.0\ && D:\dotnet.-script\App\bin\Debug\net8.0\App.exe "%scriptPath%" "Question"
标签:bat,shell,http,json,api,REM,curl,localhost
From: https://www.cnblogs.com/zhuoss/p/18365354