Scheduled research persona generation
This commit is contained in:
@@ -16,8 +16,8 @@ import {
|
||||
UsageStatsSchema,
|
||||
} from '../types/billing';
|
||||
|
||||
// API base configuration
|
||||
const API_BASE_URL = process.env.REACT_APP_API_URL || 'http://localhost:8000';
|
||||
// API base configuration - consistent with client.ts pattern
|
||||
const API_BASE_URL = process.env.REACT_APP_API_URL || process.env.REACT_APP_BACKEND_URL || '';
|
||||
|
||||
// Create axios instance with default config
|
||||
const billingAPI = axios.create({
|
||||
|
||||
@@ -308,9 +308,7 @@ export const blogWriterApi = {
|
||||
},
|
||||
|
||||
async pollResearchStatus(taskId: string): Promise<TaskStatusResponse> {
|
||||
console.log('Polling research status for task:', taskId);
|
||||
const { data } = await pollingApiClient.get(`/api/blog/research/status/${taskId}`);
|
||||
console.log('Research status response:', data);
|
||||
return data;
|
||||
},
|
||||
|
||||
|
||||
@@ -77,8 +77,8 @@ class HallucinationDetectorService {
|
||||
private baseUrl: string;
|
||||
|
||||
constructor() {
|
||||
// Use environment variable or default to localhost
|
||||
this.baseUrl = process.env.REACT_APP_API_URL || 'http://localhost:8000';
|
||||
// Consistent API URL pattern - no hardcoded localhost fallback
|
||||
this.baseUrl = process.env.REACT_APP_API_URL || process.env.REACT_APP_BACKEND_URL || '';
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -15,8 +15,8 @@ import {
|
||||
CacheStatsSchema,
|
||||
} from '../types/monitoring';
|
||||
|
||||
// API base configuration
|
||||
const API_BASE_URL = process.env.REACT_APP_API_URL || 'http://localhost:8000';
|
||||
// API base configuration - consistent with client.ts pattern
|
||||
const API_BASE_URL = process.env.REACT_APP_API_URL || process.env.REACT_APP_BACKEND_URL || '';
|
||||
|
||||
// Create axios instance for monitoring APIs
|
||||
const monitoringAPI = axios.create({
|
||||
|
||||
@@ -12,7 +12,8 @@ import {
|
||||
CopilotSuggestion
|
||||
} from '../types/seoCopilotTypes';
|
||||
|
||||
const API_BASE_URL = process.env.REACT_APP_API_BASE_URL || 'http://localhost:8000';
|
||||
// Consistent API URL pattern - use same env vars as other services
|
||||
const API_BASE_URL = process.env.REACT_APP_API_URL || process.env.REACT_APP_BACKEND_URL || '';
|
||||
|
||||
class SEOApiService {
|
||||
private baseUrl: string;
|
||||
|
||||
@@ -21,7 +21,8 @@ export interface WASuggestResponse {
|
||||
class WritingAssistantService {
|
||||
private baseUrl: string;
|
||||
constructor() {
|
||||
this.baseUrl = process.env.REACT_APP_API_URL || 'http://localhost:8000';
|
||||
// Consistent API URL pattern - no hardcoded localhost fallback
|
||||
this.baseUrl = process.env.REACT_APP_API_URL || process.env.REACT_APP_BACKEND_URL || '';
|
||||
}
|
||||
|
||||
async suggest(text: string): Promise<WASuggestion[]> {
|
||||
|
||||
Reference in New Issue
Block a user