调试接口Swagger或Postman都很方面做单个接口测试,但前者不适合生产环境,后都比较重,每次想起它都会卡在下载过程中。直到今天偶遇到VSCode插件Restclient
Main Features
- Send/Cancel/Rerun HTTP request in editor and view response in a separate pane with syntax highlight
- Send GraphQL query and author GraphQL variables in editor
- Send cURL command in editor and copy HTTP request as cURL command
- Auto save and view/clear request history
- Compose MULTIPLE requests in a single file (separated by ### delimiter)
- View image response directly in pane
- Save raw response and response body only to local disk
- Fold and unfold response body
- Customize font(size/family/weight) in response preview
- Preview response with expected parts(headers only, body only, full response and both request and response)
- Authentication support for:
- Basic Auth
- Digest Auth
- SSL Client Certificates
- Azure Active Directory
- Microsoft Identity Platform
- AWS Signature v4
- Environments and custom/system variables support
- Use variables in any place of request(URL, Headers, Body)
- Support environment, file, request and prompt custom variables
- Interactively assign prompt custom variables per request
- Auto completion and hover support for both environment, file and request custom variables
- Diagnostic support for request, file and prompt custom variables
- Go to definition support for request and file custom variables
- Find all references support ONLY for file custom variables
- Provide system dynamic variables
- {{$guid}}
- {{$randomInt min max}}
- {{$timestamp [offset option]}}
- {{$datetime rfc1123|iso8601 [offset option]}}
- {{$localDatetime rfc1123|iso8601 [offset option]}}
- {{$processEnv [%]envVarName}}
- {{$dotenv [%]variableName}}
- {{$aadToken [new] [public|cn|de|us|ppe] [<domain|tenantId>] [aud:<domain|tenantId>]}}
- Easily create/update/delete environments and environment variables in setting file
- File variables can reference both custom and system variables
- Support environment switch
- Support shared environment to provide variables that available in all environments
- Generate code snippets for HTTP request in languages like Python, JavaScript and more!
- Remember Cookies for subsequent requests
- Proxy support
- Send SOAP requests, as well as snippet support to build SOAP envelope easily
- HTTP language support
- .http and .rest file extensions support
- Syntax highlight (Request and Response)
- Auto completion for method, url, header, custom/system variables, mime types and so on
- Comments (line starts with # or //) support
- Support json and xml body indentation, comment shortcut and auto closing brackets
- Code snippets for operations like GET and POST
- Support navigate to symbol definitions(request and file level custom variable) in open http file
- CodeLens support to add an actionable link to send request
- Fold/Unfold for request block
- Support for Markdown fenced code blocks with either http or rest
主打轻量,使用起来非常顺手,比如:前一个接口申请token,下个接口使用前一个接口的返回值的token
鼠标在哪个请求,就发起哪个请求。