This commit is contained in:
54CHA
2025-07-29 18:55:22 +03:00
parent 1da9c6ac09
commit 72a9772934
19 changed files with 923 additions and 520 deletions

View File

@ -1,8 +1,14 @@
import { PartsIndexCatalogsResponse, PartsIndexGroup, PartsIndexEntityInfoResponse } from '@/types/partsindex';
const PARTS_INDEX_API_BASE = process.env.PARTSAPI_URL+"/v1" || 'https://api.parts-index.com/v1';
const PARTS_INDEX_API_BASE = process.env.PARTSAPI_URL || 'https://api.parts-index.com';
const API_KEY = 'PI-E1C0ADB7-E4A8-4960-94A0-4D9C0A074DAE';
// Debug logging for development
if (process.env.NODE_ENV === 'development') {
console.log('🔍 PartsIndex API Base URL:', PARTS_INDEX_API_BASE);
console.log('🔍 Environment variable NEXT_PUBLIC_PARTSAPI_URL:', process.env.NEXT_PUBLIC_PARTSAPI_URL);
}
class PartsIndexService {
/**
* Получить список каталогов