Giter VIP home page Giter VIP logo

automated-requester's Introduction

Release Version Code Size

automated-requester

A tool to accomplish some automatic HTTP requests, intended to help testing backend apps.

*Currently the methods available are: GET, POST, PUT, DELETE.

Usage

To start, clone this repository and enter it. All the commands needed will run inside the repo directory.

clone https://github.com/JeanCHilger/automated-requester.git
cd automated-requester

About parameter files

A parameter file is a .txt file with the name of the desired HTTP parameter, that is, the name of a parameter file is in the form: parameter-key.txt.

  • If the required parameter needs to be a text (string) it won't have any identifier get some desired values for this key and put one in each line of the file, so the requester will choose one randomly, hence the parameters will be populated automatically.
  • If the required parameter needs to be a random number it will be identified with the __TYPE@RANDOMNUMBER__ "header". Put in the first line the minimun desired value and in the second the maximun desired value.
  • If the parameter must be a path variable it will be identified with the __TYPE@PATHVAR__ "header". Just proceed as described in the two above items.

Workspaces

In order to use the core functionalities of 'automated-requester' you need to create a workspace.

Use ./requester.sh new <workspace-name> to create new workspaces.

Inside a workspace you have the tools needed to configure requests for your apps (recommended use one workspace per app). Its possible to set URLs, data samples, curl options, etc.

Management of workspaces

Once created, a workspace can be managed and configured using ./manage.sh <command> (from inside). Most of the subcommands (related to configuration purposes) require a mandatory option -m <method> to specify the targeted method.

The currently available commands are:

  • ./manage.sh run <method>: Sends the HTTP request for the specified <method>.
  • ./manage.sh showconfig <method>: Displays the current configurations for the specified <method>.
  • ./manage.sh -h: Prompts a help message with a list of available commands and their usage.
  • ./manage.sh header <header> -m <method>: Adds a header to <method> configuration file.
  • ./manage.sh param [opt] <path> -m <method>: Adds a new parameter file from <path> to the <method> parameter list.
    • opt can be -p for a path variable parameter, -r for a random number parameter or -n to create a new parameter file for the specified method.
  • ./manage.sh url <url> -m <method>: Sets the URL target for the request of the <method> method.
  • ./manage.sh verbose <option> -m <method>: Whether or not use the verbose option (-v) of the curl command when sending a <method> request.

Note: Some of the data samples are from Moby Word Lists by Grady Ward.

automated-requester's People

Contributors

jeanchilger avatar

Watchers

 avatar  avatar

automated-requester's Issues

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.