/parrot

Parrot is a mock server agent to send response for defined HTTP requests. This dev tool make the communication between client and server independant during development cycles

Primary LanguageGo

Parrot

Parrot

Parrot is a development tool to make the client and server independent during the development cycles by acting as mock server. Both front-end and back-end developer could create a separate git repository and document their request and response easy and let the parrot do the rest until these two could be connected to each other.

Features

  • Easy configuration
  • Handle JSON, HTML, and other responses as file
  • Support config hot-reload to prevent reruns

How to use

First of all, you need to create a separate directory for your mock server files. Then download parrot executable file for your system by running the command:

curl https://raw.githubusercontent.com/ARTM2000/parrot/refs/heads/master/scripts/download.bash -s | bash

After the parrot downloaded, you have to pass the mock server configuration to it. parrot by default reads the configuration from ./config.yml but you can pass the config file path with -c flag. Here is the config file sample.

After the config file prepared, you can validate it by running the following:

./parrot validate # for default path
# Or
./parrot validate -c /path/to/config.yml # for specific path

Run the parrot mock server by running the following:

./parrot run # for default path
# Or
./parrot run -c /path/to/config.yml # for specific path

Support

Feel free to open an issue if you have questions, run into bugs, or have a feature request.

Contributing

Contributions are welcome! Happy Coding :)