You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
601 B
24 lines
601 B
import { readSelectedApi } from 'helpers/selectedApi'
|
|
|
|
import { ENV, isProduction } from './env'
|
|
|
|
export const APIS = {
|
|
preproduction: {
|
|
api: 'https://api.insports.tv',
|
|
auth: 'https://auth.insports.tv',
|
|
},
|
|
production: {
|
|
api: 'https://api.insports.tv',
|
|
auth: 'https://auth.insports.tv',
|
|
},
|
|
staging: {
|
|
api: 'https://api.test.insports.tv',
|
|
auth: 'https://auth.test.insports.tv',
|
|
},
|
|
}
|
|
|
|
const env = isProduction ? ENV : readSelectedApi() ?? ENV
|
|
|
|
export const AUTH_SERVICE = APIS[env].auth
|
|
export const API_ROOT = APIS[env].api
|
|
export const DATA_URL = `${API_ROOT}/data`
|
|
|