- Adapt Sync Wordpress Component to Catalog introduction

- Small bug fixes
This commit is contained in:
Josako
2024-10-17 10:31:13 +02:00
parent 7f12c8b355
commit 74cc7ae95e
12 changed files with 94 additions and 30 deletions

View File

@@ -13,6 +13,7 @@ class EveAI_API {
$this->api_key = get_option('eveai_api_key');
$this->access_token = get_option('eveai_access_token');
$this->token_expiry = get_option('eveai_token_expiry', 0);
$this->catalog_id = get_option('eveai_catalog_id');
}
private function ensure_valid_token() {
@@ -111,6 +112,7 @@ class EveAI_API {
}
public function add_url($data) {
$data['catalog_id'] = get_option('eveai_catalog_id'); // Include catalog_id
return $this->make_request('POST', '/api/v1/documents/add_url', $data);
}