Insomnia API REST клиент. Введение.
Хотелось рассказать об одном инструменте, который может значительно упростить жизнь разработчику, который взаимодействует каким-то образом со сторонними API. Этот инструмент называется Insomnia.
По сути, это просто программа, которую вы можете сказать для вашей операционной системы и бесплатно ей пользоваться. Эта программа представляет собой так называемый API клиент.
Есть и другие альтернативы этой программы, например Postman, но везде смысл одинаковый — это клиент для взаимодействия с API.
Чтобы скачать этот клиент, можно перейти на сайт
Там есть бесплатная версия и для вашей операционной системы это приложение будет скачано.
После того, как вы его установите, у вас откроется окно, в котором можно будет взаимодействовать со сторонними API.
А зачем мне, вообще, эта программа, когда я могу написать программный код вручную? Дело в том, что с помощью этой программы можно общаться со сторонними апи значительно быстрее, чем бы вы написали какой-то программный код.
Представьте, что для того, чтобы написать какой-то программный код нужно создать папку с проектом, какие-то файлы в ней, потом начать писать код, установить какие-то сторонние библиотеки, развернуть среду окружения для всего этого и после этого у вас только начнет все работать.
В случае с апи клиентом insomnia, вы можете намного проще все это организовать. Просто запускаем программу и для того, чтобы выполнить запрос к стороннему апи, создаем новый запрос, даем ему имя и выбираем тип запроса.
У вас появиться такая вкладка, в которой вы можете настроить настройки этого запроса, который будет выполняться к стороннему апи и в правой колонке будет выводиться тот результат, который должен прийти от стороннего апи.
Это намного более просто и быстрее, чем мы бы писали программный код. Указали адрес, указали тип запроса, отправили запрос и получили результат.
Вот такой удобный REST-клиент.
The Collaborative API Client and Design Tool
Build and test APIs quickly with our streamlined API client and collaborative API design tool.
Easily organize your requests
Everything begins here. Organize your requests to reflect your workflow or your API data-model. Group and order your API requests to your heart’s desire.
Manage multiple environments
Define environment variables like authentication credentials, tokens, or session IDs for re-use globally or within a public / private environment for a seamless development / production workflow.
Multi-protocol Support
Create, organize, share and execute any REST, SOAP, GraphQL, GRPC requests directly from Insomnia without having to switch applications.
Develop faster with Code Generation
Reduce your time to market, and let Insomnia do the heavy lifting by providing you with generated code snippets in popular languages like Curl, NodeJS, Go, Swift, Python, Java, C, and more.
A theme for everyone
Dark mode? Light Mode? We have you covered. Get started quickly with Insomnia’s intuitive interface, and choose from one of our pre-bundled nine unique themes to custom tailor your experience.
Saved searches
Use saved searches to filter your results more quickly
Cancel Create saved search
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
Kong / insomnia Public
The open-source, cross-platform API client for GraphQL, REST, WebSockets and gRPC.
License
Kong/insomnia
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Switch branches/tags
Branches Tags
Could not load branches
Nothing to show
Could not load tags
Nothing to show
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Cancel Create
- Local
- Codespaces
HTTPS GitHub CLI
Use Git or checkout with SVN using the web URL.
Work fast with our official CLI. Learn more about the CLI.
Sign In Required
Please sign in to use Codespaces.
Launching GitHub Desktop
If nothing happens, download GitHub Desktop and try again.
Launching GitHub Desktop
If nothing happens, download GitHub Desktop and try again.
Launching Xcode
If nothing happens, download Xcode and try again.
Launching Visual Studio Code
Your codespace will open once ready.
There was a problem preparing your codespace, please try again.
Latest commit
e0ec076 Sep 29, 2023
Git stats
Files
Failed to load latest commit information.
Latest commit message
Commit time
September 27, 2023 14:58
September 24, 2023 23:12
September 29, 2023 13:12
December 15, 2022 17:10
September 26, 2023 13:19
August 10, 2023 17:53
August 10, 2023 17:53
August 10, 2023 00:14
March 30, 2022 12:45
August 10, 2023 17:53
April 21, 2023 10:32
August 13, 2023 12:30
July 4, 2023 22:55
May 20, 2022 12:36
January 9, 2023 16:13
August 13, 2023 12:30
May 20, 2019 11:24
August 10, 2023 00:14
July 10, 2023 23:54
May 17, 2022 08:18
September 28, 2023 20:04
August 13, 2023 12:30
July 4, 2023 22:55
August 10, 2023 00:14
June 27, 2022 12:57
README.md
Insomnia API Client
Insomnia is an open-source, cross-platform API client for GraphQL, REST, WebSockets, Server-sent events and gRPC.
Download
Insomnia is available for Mac, Windows, and Linux and can be downloaded from the website.
Bugs and Feature Requests
Have a bug or a feature request? First, read the issue guidelines and search for existing and closed issues. If your problem or idea is not addressed yet, please open a new issue.
For more generic product questions and feedback, join the Slack Team.
Contributing
Please read through our contributing guidelines and code of conduct. Included are directions for opening issues, coding standards, and notes on development.
Documentation
Develop Insomnia
Development on Insomnia can be done on Mac, Windows, or Linux as long as you have Node.js and Git. See the .nvmrc file located in the project for the correct Node version.
Initial Dev Setup
This repository is structured as a monorepo and contains many Node.JS packages. Each package has its own set of commands, but the most common commands are available from the root package.json and can be accessed using the npm run … command. Here are the only three commands you should need to start developing on the app.
# Install and Link Dependencies npm i # Run Lint npm run lint # Run type checking npm run type-check # Run Tests npm test # Start App with Live Reload npm run dev
Linux
If you are on Linux, you may need to install the following supporting packages:
# Update library sudo apt-get update # Install font configuration library & support sudo apt-get install libfontconfig-dev
# Install libcurl for node-libcurl sudo dnf install libcurl-devel
Also on Linux, if Electron is failing during the install process, run the following
# Clear Electron install conflicts rm -rf ~/.cache/electron
Windows
If you are on Windows and have problems, you may need to install Windows Build Tools
You can use any editor you’d like, but make sure to have support/plugins for the following tools:
- ESLint — For catching syntax problems and common errors
- JSX Syntax — For React components
Develop Inso CLI
- npm i
- Start the compiler in watch mode: npm run inso-start
- Run: ./packages/insomnia-inso/bin/inso -v
Plugins
Search for, discover, and install plugins from the Insomnia Plugin Hub!
Community Projects
- Insomnia Documenter — Generate beautiful API documentation pages using the documenter plugin or your Insomnia export file.
- GitHub API Spec Importer — A complete set of GitHub REST API route specifications that can be imported straight into Insomnia.
- Swaggymnia — Generate Swagger documentation for your existing API in Insomnia.
License
About
The open-source, cross-platform API client for GraphQL, REST, WebSockets and gRPC.
При подготовке материала использовались источники:
https://webkyrs.info/page/insomnia-api-rest-klient-vvedenie
https://insomnia.rest/products/insomnia
https://github.com/Kong/insomnia