Giter VIP home page Giter VIP logo

make_requests_cli's Introduction

HTTP Request Helper

Description

make_requests_cli is a command-line interface (CLI) tool built in Go (Golang) that allows users to interactively create and manage HTTP requests. It provides a simple and intuitive way to perform CRUD (Create, Read, Update, Delete) operations on requests, as well as sending HTTP requests to a specified endpoint.

Features

  • Create, read, and delete templates
  • Create, read, and delete requests
  • Send HTTP POST, GET, and DELETE requests
  • Interactive user interface for easy operation

Setup

To use make_requests_cli, follow these steps:

  1. Clone the repository or download the source code.
git clone https://github.com/omar0ali/make_requests_cli
  1. Install Go if you haven't already (https://golang.org/doc/install).
  2. Navigate to the project directory in your terminal.
  3. Build the application by running go build ..
  4. Run the application. go run .
  5. Follow the prompts to interactively create and manage templates and requests, as well as send HTTP requests.

Example Usage: Without Using Tview UI Design Improvement

Here's an example of how to use make_requests_cli:

  1. Run the application.
  2. Follow the prompts to create a template with a specified URL, port number, and HTTPS option.
  3. Create a request using the created template and specify the path.
  4. Select the request type (POST, GET, DELETE) and enter any required data.
  5. Send the HTTP request and view the response.

Example Usage: With Tview UI Design Improvement

(Under Development)

TView Library (https://github.com/rivo/tview)

To try a demo make the following changes to the app.go file.

func main() {
	database.Connect()
	sqlDB, err := database.DB.DB()
	if err != nil {
		panic("Problem: with getting db.")
	}
	defer sqlDB.Close()

	RunApp(NEW)
    //RunApp(OLD)
}

Notes

  • The application provides guidance and reminders throughout the process, such as reminding users that field names are case-sensitive and should match the backend.
  • There are multiple ways to close the application: you can choose the '0' option to exit, or you can close it by pressing CTRL+C.
  • Note: This app might not be easy or convenient to use for everyone, although I created it to make my workflow easier for testing my backend API and other tasks.

Dependencies

Note

This project is developed as a learning exercise in Golang. While efforts have been made to ensure its functionality, there may be bugs or errors present.

License

This project is licensed under the MIT License. See the LICENSE file for details.

make_requests_cli's People

Contributors

omar0ali avatar

Watchers

 avatar

make_requests_cli's Issues

Test HTTP Requests

Need some testing, especially for the HTTP requests.

Steps:

  1. Perform HTTP requests in various scenarios.
  2. Note any unexpected behavior.

Add Update Request

Currently, the application supports GET, POST, and DELETE requests, but it also needs to include an UPDATE request.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.