# Env and keyword mapping

**URL:** <https://community.auth0.com/t/env-and-keyword-mapping/73726>\
**Category:** Get Help\
**Tags:** auth0-deploy-cli\
**Created:** [November 24, 2021, 5:54pm UTC](https://community.auth0.com/t/env-and-keyword-mapping/73726 "2021-11-24T17:54:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kevin.shrestha](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/kevin.shrestha/32/33237_2.png) [@kevin.shrestha](https://community.auth0.com/u/kevin.shrestha)\
**Post date:** [November 24, 2021, 5:54pm UTC](https://community.auth0.com/t/env-and-keyword-mapping/73726/1 "2021-11-24T17:54:08Z")

</div>

Hello, I’m trying to set up a JSON config for a dev environment and later pushing towards a staging env but I’m getting errors when importing/exporting.

**Command:**

- a0deploy import --config\_file config.json --input\_file tenant.yaml

- a0deploy export --config\_file config.json --format yaml --output\_folder /…

**Errors:**

- error: Problem running command import
- error: connect ECONNREFUSED 127.0.0.1:443

**JSON File**

```auto
{
“AUTH0_DOMAIN”: “”,
“AUTH0_CLIENT_ID”: “”,
“AUTH0_CLIENT_SECRET”: “”,
“AUTH0_TENANT_NAME”: “”,
“SES_ACCESS_KEY_ID”: “”,
“SES_ACCESS_SECRET_KEY”: “”,
"AUTH0_KEYWORD_REPLACE_MAPPINGS": {
    "AUTH0_DOMAIN": "##AUTH0_DOMAIN##",
    "AUTH0_CLIENT_ID": "##AUTH0_CLIENT_ID##",
    "AUTH0_CLIENT_SECRET": "##AUTH0_CLIENT_SECRET##",
    "AUTH0_TENANT_NAME": "##AUTH0_TENANT_NAME##", 
    "SES_ACCESS_KEY_ID": "##SES_ACCESS_KEY_ID##", 
    "SES_ACCESS_SECRET_KEY": "##SES_ACCESS_SECRET_KEY##"
  },
  "AUTH0_ALLOW_DELETE": false,
  "AUTH0_EXCLUDED_RULES": ["rule-1-name"]
}

```

I have all the mappings set to an env file and if we hard code all values, it works. How do I fix this connection issue?

---

<div class="post-metadata">

**Author:** ![SaqibHussain](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/saqibhussain/32/42924_2.png) [@SaqibHussain](https://community.auth0.com/u/SaqibHussain)\
**Post date:** [November 25, 2021, 7:01pm UTC](https://community.auth0.com/t/env-and-keyword-mapping/73726/2 "2021-11-25T19:01:29Z")

</div>

Hi @kevin.shrestha

Thanks for getting in touch with us here at Auth0 Community.

The JSON file that contains AUTH0\_KEYWORD\_REPLACE\_MAPPINGS is your config so it needs to be hardcoded but you might have multiple version e.g. dev-config.json, prod-config.json and you’ll pass in the relevant config into the import/export command depending on which env is involved.

The Client/Tenant.json or YAML file is where you’ll have a single version and this is where the ##AUTH0\_DOMAIN## variables will need to go. Please see [https://auth0.com/docs/deploy/deploy-cli-tool/environment-variables-and-keyword-mappings](https://auth0.com/docs/deploy/deploy-cli-tool/environment-variables-and-keyword-mappings) for more info on this.

I hope this resolves the issue for you, any other questions please let me know.  
Regards

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [December 7, 2021, 2:27pm UTC](https://community.auth0.com/t/env-and-keyword-mapping/73726/3 "2021-12-07T14:27:46Z")

</div>


