This commit is contained in:
Your Name
2026-07-08 15:10:29 +00:00
parent d63ed3e7ef
commit 8f0f0cd36e
22 changed files with 1129 additions and 1032 deletions
+13 -2
View File
@@ -1,3 +1,16 @@
export type TrueApiEnv = 'sandbox' | 'prod'
export const envUrls: Record<TrueApiEnv, { baseUrl: string; publicCheckUrl: string }> = {
sandbox: {
baseUrl: process.env.SANDBOX_URL || 'https://markirovka.sandbox.crptech.ru/api/v3/true-api',
publicCheckUrl: process.env.SANDBOX_PUBLIC_CHECK_URL || 'https://mobile.api.crpt.ru/mobile/check',
},
prod: {
baseUrl: process.env.PROD_URL || 'https://markirovka.crpt.ru/api/v3/true-api',
publicCheckUrl: process.env.PROD_PUBLIC_CHECK_URL || 'https://mobile.api.crpt.ru/mobile/check',
},
}
export const config = {
port: parseInt(process.env.PORT || '3001', 10),
host: process.env.HOST || '0.0.0.0',
@@ -5,8 +18,6 @@ export const config = {
corsOrigin: process.env.CORS_ORIGIN || '*',
trueApi: {
baseUrl: process.env.TRUE_API_URL || 'https://markirovka.sandbox.crptech.ru/api/v3/true-api',
publicCheckUrl: process.env.PUBLIC_CHECK_URL || 'https://mobile.api.crpt.ru/mobile/check',
authPath: '/auth',
cisesInfoPath: '/cises/info',
codesCheckPath: '/codes/check',