From 6605cba2d6dc66cb4bf96fac21b32b903ea1a1b3 Mon Sep 17 00:00:00 2001 From: Aldrik Ramaekers Date: Mon, 12 Jan 2026 17:01:55 +0100 Subject: refactorings --- src/providers/openAI.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/providers/openAI.cpp') diff --git a/src/providers/openAI.cpp b/src/providers/openAI.cpp index 5659465..04981d1 100644 --- a/src/providers/openAI.cpp +++ b/src/providers/openAI.cpp @@ -26,7 +26,7 @@ static bool _openAI_batch_query_with_file(const char** queries, size_t query_count, const char* file_id, invoice* buffer, importer::batch_query_response_handler response_handler) { - const char *api_key = administration::get_active_ai_service().api_key_public; + const char *api_key = administration::get_active_ai_service().api_key; httplib::SSLClient cli("api.openai.com", 443); thrd_t threads[20]; @@ -96,7 +96,7 @@ static bool _openAI_batch_query_with_file(const char** queries, size_t query_cou static bool _openAI_query_with_file(const char* query, size_t query_length, const char* file_id, char** response) { - const char *api_key = administration::get_active_ai_service().api_key_public; + const char *api_key = administration::get_active_ai_service().api_key; httplib::SSLClient cli("api.openai.com", 443); //cli.enable_server_certificate_verification(false); @@ -135,7 +135,7 @@ static bool _openAI_query_with_file(const char* query, size_t query_length, cons static bool _openAI_upload_file(const char* file_path, char* file_id, size_t file_id_len) { - const char *api_key = administration::get_active_ai_service().api_key_public; + const char *api_key = administration::get_active_ai_service().api_key; const char *filename = strops::get_filename(file_path); FILE* orig_file = fopen(file_path, "rb"); @@ -237,7 +237,7 @@ static bool _openAI_upload_file(const char* file_path, char* file_id, size_t fil static bool _openAI_get_available_models(importer::model_list_request* buffer) { - const char *api_key = administration::get_active_ai_service().api_key_public; + const char *api_key = administration::get_active_ai_service().api_key; httplib::SSLClient cli("api.openai.com", 443); -- cgit v1.2.3-70-g09d2