diff --git a/backend/services/trading-service/Dockerfile b/backend/services/trading-service/Dockerfile index 8b9a6303..9cf9d0d6 100644 --- a/backend/services/trading-service/Dockerfile +++ b/backend/services/trading-service/Dockerfile @@ -45,6 +45,6 @@ ENV TZ=Asia/Shanghai EXPOSE 3022 HEALTHCHECK --interval=30s --timeout=10s --start-period=60s --retries=3 \ - CMD curl -f http://localhost:3022/api/v1/health || exit 1 + CMD curl -f http://localhost:3022/api/v2/health || exit 1 CMD ["/app/start.sh"] diff --git a/backend/services/trading-service/src/application/services/transfer.service.ts b/backend/services/trading-service/src/application/services/transfer.service.ts index fc876366..c921f39c 100644 --- a/backend/services/trading-service/src/application/services/transfer.service.ts +++ b/backend/services/trading-service/src/application/services/transfer.service.ts @@ -184,7 +184,7 @@ export class TransferService { transferNo: string, ): Promise<{ success: boolean; txId?: string; message?: string }> { try { - const response = await fetch(`${this.miningServiceUrl}/api/v1/mining/accounts/${accountSequence}/transfer-out`, { + const response = await fetch(`${this.miningServiceUrl}/api/v2/mining/accounts/${accountSequence}/transfer-out`, { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ amount, transferNo }), @@ -203,7 +203,7 @@ export class TransferService { transferNo: string, ): Promise<{ success: boolean; txId?: string; message?: string }> { try { - const response = await fetch(`${this.miningServiceUrl}/api/v1/mining/accounts/${accountSequence}/transfer-in`, { + const response = await fetch(`${this.miningServiceUrl}/api/v2/mining/accounts/${accountSequence}/transfer-in`, { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ amount, transferNo }), diff --git a/backend/services/trading-service/src/main.ts b/backend/services/trading-service/src/main.ts index c94dffee..8bafce22 100644 --- a/backend/services/trading-service/src/main.ts +++ b/backend/services/trading-service/src/main.ts @@ -20,7 +20,7 @@ async function bootstrap() { credentials: true, }); - app.setGlobalPrefix('api/v1'); + app.setGlobalPrefix('api/v2'); const config = new DocumentBuilder() .setTitle('Trading Service API')