Skip to content

andteki/resen

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Resen

The Resen a command-line HTTP client.

Simple command-line HTTP client.

GitHub:

Why

The HTTPie command is a very good program, but it cannot be installed with the npm package manager. What we have is not a command line program.

Install

npm i -g resen

After installation, we get a res command. Check:

res --version

Using

Methods that can be used:

  • get
  • post
  • put
  • patch
  • delete

Syntax

res [method] <url> [params...]

Examples

GET method:

res https://localhost:8000/employees
res localhost:8000/employees
res get localhost:8000/employees

POST method:

res post localhost:8000/employees name='Steven' city='Szeged'

PUT method:

res put localhost:8000/employees/1 name='Steven' city='Szeged'

PATCH method:

res patch localhost:8000/employees/1 name='Steven' city='Szeged'

DELETE method:

res delete localhost:8000/employees/1

Authentication

Options:

  • --auth-type bearer
  • --auth token

Currently, only the Bearer token is supported.

Using example:

res delete localhost:8000/employees 
--auth-type bearer --auth f3a434...

Short form:

res delete localhost:8000/employees 
-A bearer -a f3a434...

About

Comand-line HTTP client

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published