# http-requests-tester

> It's a CLI HTTP tester based on HTTP client and HTTP tests implemented in PHPStorm.

Latest version **1.2.4** (published 2022-10-31) · ISC license · 0 weekly downloads

## Install

```sh
npm install http-requests-tester
pnpm add http-requests-tester
yarn add http-requests-tester
bun add http-requests-tester
```

Provides the command `http-requests-tester`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.2.4 |
| Published | 2022-10-31 |
| First published | 2021-09-07 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 51.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Sebastian Niecikowski |
| Maintainers | snitool |
| Keywords | phpstorm, http, https, test, tests, requests, tester, jetbrains |

## Links

- npm: https://www.npmjs.com/package/http-requests-tester
- npm.io page: https://npm.io/package/http-requests-tester

## Dependencies (1)

- [qs](https://npm.io/package/qs.md) ^6.11.0

## Alternatives

- [duck](https://npm.io/package/duck.md) — 4.2M weekly downloads
- [ava](https://npm.io/package/ava.md) — 560.2K weekly downloads
- [storybook-addon-module-mock](https://npm.io/package/storybook-addon-module-mock.md) — 71.7K weekly downloads
- [@ethereum-waffle/mock-contract](https://npm.io/package/@ethereum-waffle/mock-contract.md) — 40.0K weekly downloads
- [aws-elasticsearch-connector](https://npm.io/package/aws-elasticsearch-connector.md) — 37.4K weekly downloads

## Recent versions

- 1.2.4 (latest) — 2022-10-31
- 1.2.3 — 2022-08-08
- 1.2.2 — 2022-08-08
- 1.2.1 — 2021-11-30
- 1.2.0 — 2021-11-30
- 1.1.1 — 2021-11-29
- 1.1.0 — 2021-11-23
- 1.0.19 — 2021-11-16
- 1.0.18 — 2021-11-13
- 1.0.17 — 2021-11-01
- 1.0.16 — 2021-10-20
- 1.0.15 — 2021-10-05
- 1.0.14 — 2021-10-04
- 1.0.13 — 2021-09-28
- 1.0.12 — 2021-09-27
- … 12 more at https://npm.io/package/http-requests-tester/versions

## README

# HTTP requests tester
It's a CLI HTTP tester based on HTTP client and HTTP tests implemented in PHPStorm.

Github repo: https://github.com/nitool/http-requests-tester

NPM package: https://www.npmjs.com/package/http-requests-tester 

## Installation and usage
Install:
```bash
npm install -g http-requests-tester
```

Usage:
```bash
npx http-requests-tester --selected-client clientName --client-file rest-client.env.json test_file.http 
```

Test file example:
```http
# Example test
GET http://httpbin.org/status/200
Accept: text/plain

> {%
    client.test('example test set', function () {
        client.log('example log')
        client.assert(response.status === 200, 'it does not work')
    })
%}
```

## Status:
It works but work is still in progress. Package needs refactor and unit tests.

## Resources: 
- https://www.jetbrains.com/help/phpstorm/exploring-http-syntax.html
- https://www.jetbrains.com/help/phpstorm/http-client-reference.html

## Options:
```
--client-file=path_to_file.json - config file with possible clients
--selected-client='name' - each client file can contain multiple clients, this options is required and selects config to use while making request
--help|-h - shows help message
--verbose|-v - show logs, by default only errors are printed out
--autolog-response - logs every received response when verbose is enabled
```

---
_Source: https://npm.io/package/http-requests-tester · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
