question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature Request] Command line switches for Insomnia

See original GitHub issue

As agreed with Insomnia support I’m creating this feature request with list of commands line switches I want you to implement in the first iteration. #479 is indeed too vague and is more like an epic which has to be split in smaller tasks.

  • Insomnia Version: 5.x
  • Operating System: macOS, Linux, Windows

Details

What about implementing the following functionality as part of the first commandline-related iteration:

insomnia --workspace|-w "Foo Bar" --request-id|-r 00000000aaabbbbccccc0000000` 

with these switches I would expect Insomnia to open and switch to workspace Foo Bar (not sure if it’s really needed) and send the request with the following ID req_00000000aaabbbbccccc0000000

I would also like to have the second option for cases when I haven’t created any workspace / request in Insomnia, so I could explicitly indicate the URL, HTTP request type, headers etc

# Calls https://api.acme.com/v1.0/users URL with Accept: application/json header
insomnia --header|-H "Accept: application/json" https://api.acme.com/v1.0/users

# Sends a PUT request to https://api.acme.com/v1.0/users URL with
# Content-Type: application/json header and some JSON-encoded data
insomnia  --request-type|-X PUT \
                --header|-H "Content-Type: application/json" \
                --data|-d '{"name":"john","email":"j@acme.com"}' \
               https://api.acme.com/v1.0/users

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:5
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
salaroscommented, Apr 25, 2018

So do you have any ETA on this? I’m willing to donate or pay for a subscription etc if you implement this feature 👍

2reactions
salaroscommented, Feb 1, 2018

@gschier personally I like cURL syntax more, please read my proposal more carefully. IMO cURL’s command line options have a cleaner and better documented options.

As for why I need it:

  • I would like to be able to set Insomnia as “browser” while debugging APIs in Visual Studio / VS Code / Atom, so that it IDE will use it in its post build scripts image

  • Additionally I would like to be able to include some scripts into my repositories. In this scripts I could call APIs using the awesome Insomnia software and fallback on cURL if Insomnia is not installed.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Introduction to Inso CLI - Insomnia Docs
Inso CLI (Command Line Interface) for Insomnia is built on Node.js and the Insomnia core libraries. It allows you to use Insomnia application...
Read more >
Use Insomnia for API Requests
In this topic, you will learn how to set up the popular Insomnia HTTP client to make requests to the Brightcove RESTful APIs....
Read more >
Powercfg command-line options - Microsoft Learn
Sets a security descriptor associated with a power setting, power scheme, or action. /hibernate, /H, Enables and disables the hibernate feature.
Read more >
Insomnia REST Client Intro - KishStats
Insomina offers several nice options for exporing requests. You can generate CURL commands to run using the command line. You can also generate ......
Read more >
Insomnia REST Client Tutorial - YouTube
Your browser can't play this video. Learn more. Switch camera.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found