What is base API on Insomnia
How to use Insomnia
If you find {{ base_api }} on insomnia its avariable that save your environment setting like :
{
"base_url": "<http://localhost:3000>",
"access_token": "YWnDsCHFzA81yH2NrAb-lJHc09MCZZjSGDgbxHeUguY",
"gb_primepay_url": "<https://api.globalprimepay.com>"
}
that {{ base_api }} will call “base_url” on the environment
On Insomnia as default we have 4 environment :
- Stagging use this if you want to get data from old stagging server, and if you want data from new stagging just change the “base_url”
{
"base_url": "<https://hhstaging.hungryhub.com>",
"access_token": "J-Os2M5aOUia69n7m4QV2MeYNJJ8Xdfocmlb-gF-0CE",
"gb_primepay_url": "<https://api.globalprimepay.com>"
}
- Dev use this if you want to get data from local server
{
"base_url": "<http://localhost:3000>",
"access_token": "YWnDsCHFzA81yH2NrAb-lJHc09MCZZjSGDgbxHeUguY",
"gb_primepay_url": "<https://api.globalprimepay.com>"
}
- Production use this if you want to get data from production
{
"base_url": "<https://www.hungryhub.com>",
"access_token": "YWnDsCHFzA81yH2NrAb-lJHc09MCZZjSGDgbxHeUguY",
"gb_primepay_url": "<https://api.gbprimepay.com>"
}
- Ngrox use this if you want to get data from ngrox server
{
"base_url": "<https://2bb1fc73c6ed.ngrok.io>",
"access_token": "YWnDsCHFzA81yH2NrAb-lJHc09MCZZjSGDgbxHeUguY",
"gb_primepay_url": "<https://api.globalprimepay.com>"
}