@@ -595,6 +595,12 @@ struct SessionConfig
595595 std::optional<std::map<std::string, json>> mcp_servers;
596596 std::optional<std::vector<CustomAgentConfig>> custom_agents;
597597
598+ // / Directories to load skills from.
599+ std::optional<std::vector<std::string>> skill_directories;
600+
601+ // / List of skill names to disable.
602+ std::optional<std::vector<std::string>> disabled_skills;
603+
598604 // / Infinite session configuration for persistent workspaces and automatic compaction.
599605 // / When enabled (default), sessions automatically manage context limits and persist state.
600606 std::optional<InfiniteSessionConfig> infinite_sessions;
@@ -614,6 +620,12 @@ struct ResumeSessionConfig
614620 std::optional<std::map<std::string, json>> mcp_servers;
615621 std::optional<std::vector<CustomAgentConfig>> custom_agents;
616622
623+ // / Directories to load skills from.
624+ std::optional<std::vector<std::string>> skill_directories;
625+
626+ // / List of skill names to disable.
627+ std::optional<std::vector<std::string>> disabled_skills;
628+
617629 // / If true and provider not explicitly set, load from COPILOT_SDK_BYOK_* env vars.
618630 // / Default: false (explicit configuration preferred over environment variables)
619631 bool auto_byok_from_env = false ;
@@ -833,4 +845,120 @@ inline void from_json(const json& j, PingResponse& r)
833845 r.protocol_version = j.at (" protocolVersion" ).get <int >();
834846}
835847
848+ // / Response from status.get request
849+ struct GetStatusResponse
850+ {
851+ std::string version;
852+ int protocol_version;
853+ };
854+
855+ inline void from_json (const json& j, GetStatusResponse& r)
856+ {
857+ j.at (" version" ).get_to (r.version );
858+ j.at (" protocolVersion" ).get_to (r.protocol_version );
859+ }
860+
861+ // / Response from auth.getStatus request
862+ struct GetAuthStatusResponse
863+ {
864+ bool is_authenticated;
865+ std::optional<std::string> auth_type;
866+ std::optional<std::string> host;
867+ std::optional<std::string> login;
868+ std::optional<std::string> status_message;
869+ };
870+
871+ inline void from_json (const json& j, GetAuthStatusResponse& r)
872+ {
873+ j.at (" isAuthenticated" ).get_to (r.is_authenticated );
874+ if (j.contains (" authType" ) && !j[" authType" ].is_null ())
875+ r.auth_type = j[" authType" ].get <std::string>();
876+ if (j.contains (" host" ) && !j[" host" ].is_null ())
877+ r.host = j[" host" ].get <std::string>();
878+ if (j.contains (" login" ) && !j[" login" ].is_null ())
879+ r.login = j[" login" ].get <std::string>();
880+ if (j.contains (" statusMessage" ) && !j[" statusMessage" ].is_null ())
881+ r.status_message = j[" statusMessage" ].get <std::string>();
882+ }
883+
884+ // / Model capabilities - what the model supports
885+ struct ModelCapabilities
886+ {
887+ struct Supports
888+ {
889+ bool vision = false ;
890+ };
891+ struct Limits
892+ {
893+ std::optional<int > max_prompt_tokens;
894+ int max_context_window_tokens = 0 ;
895+ };
896+ Supports supports;
897+ Limits limits;
898+ };
899+
900+ inline void from_json (const json& j, ModelCapabilities& c)
901+ {
902+ if (j.contains (" supports" ))
903+ {
904+ if (j[" supports" ].contains (" vision" ))
905+ j[" supports" ][" vision" ].get_to (c.supports .vision );
906+ }
907+ if (j.contains (" limits" ))
908+ {
909+ if (j[" limits" ].contains (" max_prompt_tokens" ) && !j[" limits" ][" max_prompt_tokens" ].is_null ())
910+ c.limits .max_prompt_tokens = j[" limits" ][" max_prompt_tokens" ].get <int >();
911+ if (j[" limits" ].contains (" max_context_window_tokens" ))
912+ j[" limits" ][" max_context_window_tokens" ].get_to (c.limits .max_context_window_tokens );
913+ }
914+ }
915+
916+ // / Model policy state
917+ struct ModelPolicy
918+ {
919+ std::string state;
920+ std::string terms;
921+ };
922+
923+ inline void from_json (const json& j, ModelPolicy& p)
924+ {
925+ j.at (" state" ).get_to (p.state );
926+ if (j.contains (" terms" ))
927+ j.at (" terms" ).get_to (p.terms );
928+ }
929+
930+ // / Model billing information
931+ struct ModelBilling
932+ {
933+ double multiplier = 1.0 ;
934+ };
935+
936+ inline void from_json (const json& j, ModelBilling& b)
937+ {
938+ if (j.contains (" multiplier" ))
939+ j.at (" multiplier" ).get_to (b.multiplier );
940+ }
941+
942+ // / Information about an available model
943+ struct ModelInfo
944+ {
945+ std::string id;
946+ std::string name;
947+ ModelCapabilities capabilities;
948+ std::optional<ModelPolicy> policy;
949+ std::optional<ModelBilling> billing;
950+ };
951+
952+ inline void from_json (const json& j, ModelInfo& m)
953+ {
954+ j.at (" id" ).get_to (m.id );
955+ j.at (" name" ).get_to (m.name );
956+ if (j.contains (" capabilities" ))
957+ j.at (" capabilities" ).get_to (m.capabilities );
958+ if (j.contains (" policy" ) && !j[" policy" ].is_null ())
959+ m.policy = j[" policy" ].get <ModelPolicy>();
960+ if (j.contains (" billing" ) && !j[" billing" ].is_null ())
961+ m.billing = j[" billing" ].get <ModelBilling>();
962+ }
963+
836964} // namespace copilot
0 commit comments