# fast-request
**Repository Path**: rabbit-tooth/fast-request
## Basic Information
- **Project Name**: fast-request
- **Description**: IntelliJ plugin Restful Fast Request
一个基于springmvc的帮助你快速生成url和参数的IDEA 插件。IDEA postman工具
- **Primary Language**: Java
- **License**: Apache-2.0
- **Default Branch**: master
- **Homepage**: https://plugins.jetbrains.com/plugin/16988-fast-request
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 41
- **Created**: 2021-08-31
- **Last Updated**: 2021-08-31
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# Restful Fast Request
[![Jetbrains Plugins][plugin-img]][plugin]


[](https://fastrequest.slack.com)
[**Restful Fast Request**](https://plugins.jetbrains.com/plugin/16988-fast-request) is a plugin based on springmvc that
help you quickly generate **url** and **params**.It is also a http client tool.
You only need to click the rocket icon on the left side of the method, the plugin will help you generate the method url
and parameters and display in the tool, and then click Send Request to complete the API debugging in IDEA, and you can
save the history request
Compared with the HTTP Client, Restful Fast Request not only has the built-in functions of the HTTP Client, but also
provides a friendly, easy-to-understand and intuitive interface, which makes it more convenient and simple for users to
debug the API. At the same time, various types of parameters also provide different customization methods to make it
more flexible.
> PURPOSE
> The purpose of the plug-in is to simplify development and improve efficiency. Our vision is to become the best partner of IDEA, just like Contra's 1P, 2P, base-friend collocation, and double the efficiency.
If you think this plugin help you, please **🌟Star** project, and also welcome to provide excellent recommendation

- document
* [中文文档](README.zh_CN.md)
* [English Document](README.md)
## 0.Install
**using IDE plugin system**
- recommended Preferences(Settings) > Plugins > Browse repositories... > find"
Restful Fast Request" > Install Plugin
**Manual:**
- download[`lastest plugin zip`][latest-release] -> Preferences(Settings) > Plugins > Install
plugin from disk...
## 1.How to use
```
Step1:Click Manager config then add project name[example:wx card] and env[example:local、dev]
Step2:set target domain
Step3:open toolwindow(at the top-right corner),select project and env
Step4:click fastRequest icon on method left(generate url and param)
Step5:click send button for sending request
```

## 2.Default shortcut key
recommend way:just click FastRequest icon

[comment]: <> (|key|scope|description|)
[comment]: <> (| --- | --- | --- |)
[comment]: <> (| ctrl \ | method(just put the cursor on method) | Generate the url and request parameters of the current method |)
[comment]: <> (if it doesn't work,you can search Generate URL and Param in key map and change the key)
[comment]: <> (modify key:Preferences(Settings) > Keymap)
[comment]: <> (other way:Code(Toolbar) > Generate > Generate URL and Param)
## 3.config and usage
### 3.1 common config
|config name|description|
| --- | --- |
|ProjectName|project name,Example:**user**、**order**,Please make sure there must be a project before adding env|
|Env|environment Name,Example:**local**、**develop**、**test**、**produce**|
|Domain|add the domain url in table|

### 3.2 Data Mapping
|config name|description|
| --- | --- |
|Random String Length|Random string length,default 5|
|Custom Data Mapping|If you want a class to parse only the fields you want,then you can add custom mapping configuration|
|Default Data Mapping|Default type of relational mapping,That is, the type is converted to the corresponding value|

#### 3.2.1 Custom Data Mapping
**Java Type**is the corresponding object type,must contain package name and class name
Example:`com.baomidou.mybatisplus.extension.plugins.pagination.Page`
**Default value**must be in json format,
Example:
```
{"size":10,"current":1}
```
#### 3.3 Other config
controller url fixed variable can replace by config, For example controller like this
```
@RequestMapping("/api/${api-module}/user")
@Controller
public class XxxController(){
...
}
```
the actual url is `/api/base/user`
Then `${api-module}` can be replaced by the following configuration

## 4.Type Icon Mapping
icon and type mapping
|Icon|Type|
| --- | --- |
| |Array |
| |Object |
| |Number |
| |String |
||Boolean|
||File|
## 5.Donate
If you think the plug-in is great and saves you a lot of time, then invite the author to have a cup of coffee~☕☕☕,thank you very much!
|  |  |
| --- | --- |
## 6.FAQ
>Question 1:About the console blocking the tool window
Answer:At present, when the tool window and console are visible at the same time, It does not support the display of tool windows prior to the console. So you can only adjust [view mode](https://www.jetbrains.com/help/idea/viewing-modes.html)
to control the view,Or use shortcut keys to quickly hide and show the console(shortcut:look at view->toolWindow->run/debug) to make all the content in the tool window visible。Of course, you can click to hide the Request part to see the Response
>Question 2:Why the plugin doesn't respond
Answer:Please configure the relevant configuration according to the steps introduced in the first chapter first, and then click the icon
>Question 3:idea freezes after clicking the icon
>Answer:The entity class you designed is nested and recursive, the plugin does not support
[latest-release]: https://github.com/kings1990/fast-request/releases/latest
[plugin]: https://plugins.jetbrains.com/plugin/16988
[plugin-img]: https://img.shields.io/badge/plugin-FastRequest-x.svg