Add an API key in the ETHGasStation URL (#2332)

* Add an API key in the ETHGasStation URL

* Fix typo

* Revert mainnet api key

* Add the env var in github actions

* Revert "Fix typo"

This reverts commit c9b463099d9b38d481d21f42b4cedb8eafb0b83c.
This commit is contained in:
katspaugh 2021-05-28 11:28:31 +02:00 committed by GitHub
parent 15d3cb8ff4
commit 2fdc5e05a9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 6 additions and 1 deletions

View File

@ -16,6 +16,7 @@ REACT_APP_FORTMATIC_KEY=
REACT_APP_OPENSEA_API_KEY= REACT_APP_OPENSEA_API_KEY=
REACT_APP_COLLECTIBLES_SOURCE= REACT_APP_COLLECTIBLES_SOURCE=
REACT_APP_ETHERSCAN_API_KEY= REACT_APP_ETHERSCAN_API_KEY=
REACT_APP_ETHGASSTATION_API_KEY=
# Versions # Versions
REACT_APP_LATEST_SAFE_VERSION= REACT_APP_LATEST_SAFE_VERSION=

View File

@ -21,6 +21,7 @@ env:
REACT_APP_SENTRY_DSN: ${{ secrets.SENTRY_DSN_RINKEBY }} REACT_APP_SENTRY_DSN: ${{ secrets.SENTRY_DSN_RINKEBY }}
REACT_APP_GOOGLE_ANALYTICS: ${{ secrets.REACT_APP_GOOGLE_ANALYTICS_ID_RINKEBY }} REACT_APP_GOOGLE_ANALYTICS: ${{ secrets.REACT_APP_GOOGLE_ANALYTICS_ID_RINKEBY }}
REACT_APP_GNOSIS_APPS_URL: ${{ secrets.REACT_APP_GNOSIS_APPS_URL_PROD }} REACT_APP_GNOSIS_APPS_URL: ${{ secrets.REACT_APP_GNOSIS_APPS_URL_PROD }}
REACT_APP_ETHGASSTATION_API_KEY: ${{ secrets.REACT_APP_ETHGASSTATION_API_KEY_RINKEBY }}
jobs: jobs:
debug: debug:

View File

@ -1,5 +1,6 @@
import EtherLogo from 'src/config/assets/token_eth.svg' import EtherLogo from 'src/config/assets/token_eth.svg'
import { EnvironmentSettings, ETHEREUM_NETWORK, NetworkConfig } from 'src/config/networks/network.d' import { EnvironmentSettings, ETHEREUM_NETWORK, NetworkConfig } from 'src/config/networks/network.d'
import { ETHGASSTATION_API_KEY } from 'src/utils/constants'
const baseConfig: EnvironmentSettings = { const baseConfig: EnvironmentSettings = {
clientGatewayUrl: 'https://safe-client.mainnet.staging.gnosisdev.com/v1', clientGatewayUrl: 'https://safe-client.mainnet.staging.gnosisdev.com/v1',

View File

@ -1,12 +1,13 @@
import EtherLogo from 'src/config/assets/token_eth.svg' import EtherLogo from 'src/config/assets/token_eth.svg'
import { EnvironmentSettings, ETHEREUM_NETWORK, NetworkConfig, WALLETS } from 'src/config/networks/network.d' import { EnvironmentSettings, ETHEREUM_NETWORK, NetworkConfig, WALLETS } from 'src/config/networks/network.d'
import { ETHGASSTATION_API_KEY } from 'src/utils/constants'
const baseConfig: EnvironmentSettings = { const baseConfig: EnvironmentSettings = {
clientGatewayUrl: 'https://safe-client.rinkeby.staging.gnosisdev.com/v1', clientGatewayUrl: 'https://safe-client.rinkeby.staging.gnosisdev.com/v1',
txServiceUrl: 'https://safe-transaction.rinkeby.staging.gnosisdev.com/api/v1', txServiceUrl: 'https://safe-transaction.rinkeby.staging.gnosisdev.com/api/v1',
safeAppsUrl: 'https://safe-apps.dev.gnosisdev.com', safeAppsUrl: 'https://safe-apps.dev.gnosisdev.com',
gasPriceOracle: { gasPriceOracle: {
url: 'https://ethgasstation.info/json/ethgasAPI.json', url: `https://ethgasstation.info/json/ethgasAPI.json?api-key=${ETHGASSTATION_API_KEY}`,
gasParameter: 'average', gasParameter: 'average',
}, },
rpcServiceUrl: 'https://rinkeby.infura.io:443/v3', rpcServiceUrl: 'https://rinkeby.infura.io:443/v3',

View File

@ -23,6 +23,7 @@ export const OPENSEA_API_KEY = process.env.REACT_APP_OPENSEA_API_KEY || ''
export const COLLECTIBLES_SOURCE = process.env.REACT_APP_COLLECTIBLES_SOURCE || 'Gnosis' export const COLLECTIBLES_SOURCE = process.env.REACT_APP_COLLECTIBLES_SOURCE || 'Gnosis'
export const TIMEOUT = process.env.NODE_ENV === 'test' ? 1500 : 5000 export const TIMEOUT = process.env.NODE_ENV === 'test' ? 1500 : 5000
export const ETHERSCAN_API_KEY = process.env.REACT_APP_ETHERSCAN_API_KEY export const ETHERSCAN_API_KEY = process.env.REACT_APP_ETHERSCAN_API_KEY
export const ETHGASSTATION_API_KEY = process.env.REACT_APP_ETHGASSTATION_API_KEY
export const EXCHANGE_RATE_URL = 'https://api.exchangeratesapi.io/latest' export const EXCHANGE_RATE_URL = 'https://api.exchangeratesapi.io/latest'
export const EXCHANGE_RATE_URL_FALLBACK = 'https://api.coinbase.com/v2/exchange-rates' export const EXCHANGE_RATE_URL_FALLBACK = 'https://api.coinbase.com/v2/exchange-rates'
export const SAFE_APPS_LIST_URL = export const SAFE_APPS_LIST_URL =