Cppinecone
A C++ client for the Pinecone vector database
api_metadata.hpp
Go to the documentation of this file.
1 #pragma once
7 #include <string>
8 
9 #include <nlohmann/json.hpp>
10 
11 #include "pinecone/util/result.hpp"
12 
13 namespace pinecone::types
14 {
22 struct api_metadata {
26  [[nodiscard]] auto md_project_name() const noexcept -> std::string const& { return project_name; }
27 
31  [[nodiscard]] auto md_user_label() const noexcept -> std::string const& { return user_label; }
32 
36  [[nodiscard]] auto md_user_name() const noexcept -> std::string const& { return user_name; }
37 
38  NLOHMANN_DEFINE_TYPE_INTRUSIVE(api_metadata, project_name, user_label, user_name)
39 
40  private:
41  std::string project_name;
42  std::string user_label;
43  std::string user_name;
44 };
45 } // namespace pinecone::types
STL namespace.
Models the possibility of failure for Pinecone operations.
Pinecone API metadata.
auto md_user_name() const noexcept -> std::string const &
auto md_project_name() const noexcept -> std::string const &
auto md_user_label() const noexcept -> std::string const &