#include "cyborgdb_core/client.hpp"
#include "cyborgdb_core/encrypted_index.hpp"
#include <array>
// Using `threadsafememory` storage for this example
cyborg::DBConfig index_location(cyborg::Location::kThreadSafeMemory);
cyborg::DBConfig config_location(cyborg::Location::kThreadSafeMemory);
cyborg::DBConfig contents_location(cyborg::Location::kThreadSafeMemory);
// Get your API key
std::string api_key = "your_api_key_here"; // Replace with your actual API key
// Create a client
cyborg::Client client(api_key, index_location, config_location, contents_location, 0, cyborg::kNone);
// Provide the index key used when creating the index
// Example key (32 bytes)
std::array<uint8_t, 32> index_key;
// Load an encrypted index
auto index = client.LoadIndex("my_index", index_key);