From 390eec62cca737046c2325edc255ecc9f1d0ba65 Mon Sep 17 00:00:00 2001 From: bigcat88 Date: Sun, 7 Sep 2025 14:38:35 +0300 Subject: [PATCH] update prices for Veo3 --- src/composables/node/useNodePricing.ts | 8 +++---- .../composables/node/useNodePricing.test.ts | 22 +++++++++---------- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/composables/node/useNodePricing.ts b/src/composables/node/useNodePricing.ts index b2ad2ff995..dce3befaef 100644 --- a/src/composables/node/useNodePricing.ts +++ b/src/composables/node/useNodePricing.ts @@ -1053,7 +1053,7 @@ const apiNodeCosts: Record = ) as IComboWidget if (!modelWidget || !generateAudioWidget) { - return '$2.00-6.00/Run (varies with model & audio generation)' + return '$0.80-3.20/Run (varies with model & audio generation)' } const model = String(modelWidget.value) @@ -1061,13 +1061,13 @@ const apiNodeCosts: Record = String(generateAudioWidget.value).toLowerCase() === 'true' if (model.includes('veo-3.0-fast-generate-001')) { - return generateAudio ? '$3.20/Run' : '$2.00/Run' + return generateAudio ? '$1.20/Run' : '$0.80/Run' } else if (model.includes('veo-3.0-generate-001')) { - return generateAudio ? '$6.00/Run' : '$4.00/Run' + return generateAudio ? '$3.20/Run' : '$1.60/Run' } // Default fallback - return '$2.00-6.00/Run' + return '$0.80-3.20/Run' } }, LumaImageNode: { diff --git a/tests-ui/tests/composables/node/useNodePricing.test.ts b/tests-ui/tests/composables/node/useNodePricing.test.ts index dbd40a7311..89df12a369 100644 --- a/tests-ui/tests/composables/node/useNodePricing.test.ts +++ b/tests-ui/tests/composables/node/useNodePricing.test.ts @@ -505,7 +505,7 @@ describe('useNodePricing', () => { }) describe('dynamic pricing - Veo3VideoGenerationNode', () => { - it('should return $2.00 for veo-3.0-fast-generate-001 without audio', () => { + it('should return $0.80 for veo-3.0-fast-generate-001 without audio', () => { const { getNodeDisplayPrice } = useNodePricing() const node = createMockNode('Veo3VideoGenerationNode', [ { name: 'model', value: 'veo-3.0-fast-generate-001' }, @@ -513,10 +513,10 @@ describe('useNodePricing', () => { ]) const price = getNodeDisplayPrice(node) - expect(price).toBe('$2.00/Run') + expect(price).toBe('$0.80/Run') }) - it('should return $3.20 for veo-3.0-fast-generate-001 with audio', () => { + it('should return $1.20 for veo-3.0-fast-generate-001 with audio', () => { const { getNodeDisplayPrice } = useNodePricing() const node = createMockNode('Veo3VideoGenerationNode', [ { name: 'model', value: 'veo-3.0-fast-generate-001' }, @@ -524,10 +524,10 @@ describe('useNodePricing', () => { ]) const price = getNodeDisplayPrice(node) - expect(price).toBe('$3.20/Run') + expect(price).toBe('$1.20/Run') }) - it('should return $4.00 for veo-3.0-generate-001 without audio', () => { + it('should return $1.60 for veo-3.0-generate-001 without audio', () => { const { getNodeDisplayPrice } = useNodePricing() const node = createMockNode('Veo3VideoGenerationNode', [ { name: 'model', value: 'veo-3.0-generate-001' }, @@ -535,10 +535,10 @@ describe('useNodePricing', () => { ]) const price = getNodeDisplayPrice(node) - expect(price).toBe('$4.00/Run') + expect(price).toBe('$1.60/Run') }) - it('should return $6.00 for veo-3.0-generate-001 with audio', () => { + it('should return $3.20 for veo-3.0-generate-001 with audio', () => { const { getNodeDisplayPrice } = useNodePricing() const node = createMockNode('Veo3VideoGenerationNode', [ { name: 'model', value: 'veo-3.0-generate-001' }, @@ -546,7 +546,7 @@ describe('useNodePricing', () => { ]) const price = getNodeDisplayPrice(node) - expect(price).toBe('$6.00/Run') + expect(price).toBe('$3.20/Run') }) it('should return range when widgets are missing', () => { @@ -555,7 +555,7 @@ describe('useNodePricing', () => { const price = getNodeDisplayPrice(node) expect(price).toBe( - '$2.00-6.00/Run (varies with model & audio generation)' + '$0.80-3.20/Run (varies with model & audio generation)' ) }) @@ -567,7 +567,7 @@ describe('useNodePricing', () => { const price = getNodeDisplayPrice(node) expect(price).toBe( - '$2.00-6.00/Run (varies with model & audio generation)' + '$0.80-3.20/Run (varies with model & audio generation)' ) }) @@ -579,7 +579,7 @@ describe('useNodePricing', () => { const price = getNodeDisplayPrice(node) expect(price).toBe( - '$2.00-6.00/Run (varies with model & audio generation)' + '$0.80-3.20/Run (varies with model & audio generation)' ) }) })