package util import ( "github.com/spf13/cobra" eiaapi "gitea.libretechconsulting.com/50W/eia-api-go/api" "gitea.libretechconsulting.com/50W/eia-api-go/pkg/eia" ) func GetFacet(cmd *cobra.Command, route string, facet string) (*eiaapi.FacetDetails, error) { client, err := Client(cmd) if err != nil { return nil, err } return client.GetFacet(cmd.Context(), route, facet, eia.DefaultMethodSubs(cmd.Context())) } func GetFacets(cmd *cobra.Command, route string) (*eiaapi.FacetOptionList, error) { client, err := Client(cmd) if err != nil { return nil, err } return client.GetFacets(cmd.Context(), route, eia.DefaultMethodSubs(cmd.Context())) }