Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var AttributesCmd = &cobra.Command{ Use: "attributes", Aliases: []string{"attrs"}, Short: "Manage API Product Attributes", Long: "Manage API Product Attributes", }
AttributesCmd to manage tracing of apis
View Source
var Cmd = &cobra.Command{ Use: "products", Aliases: []string{"prods"}, Short: "Manage Apigee API products", Long: "Manage Apigee API products", }
Cmd to manage products
View Source
var CreateCmd = &cobra.Command{ Use: "create", Short: "Create an API product", Long: "Create an API product", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.Create(name, description, approval, displayName, quota, quotaInterval, quotaUnit, environments, proxies, scopes, attrs) return }, }
Cmd to create a new product
View Source
var DelAttrCmd = &cobra.Command{ Use: "delete", Short: "Deletes an attribute from an API product", Long: "Deletes an attribute from an API product", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.DeleteAttribute(name, attrName) return }, }
DelAttrCmd to delete product attribute
View Source
var DelCmd = &cobra.Command{ Use: "delete", Short: "Deletes an API product from an organization", Long: "Deletes an API product from an organization", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.Delete(name) return }, }
Cmd to delete products
View Source
var ExpCmd = &cobra.Command{ Use: "export", Short: "Export API products to a file", Long: "Export API products to a file", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { const exportFileName = "products.json" payload, err := products.Export(conn) if err != nil { return } return apiclient.WriteArrayByteArrayToFile(exportFileName, false, payload) }, }
ExpCmd to export products
View Source
var GetAttrCmd = &cobra.Command{ Use: "get", Short: "Get an attribute of an API product", Long: "Get an attribute of an API product", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.GetAttribute(name, attrName) return }, }
GetAttrCmd to delete product attribute
View Source
var GetCmd = &cobra.Command{ Use: "get", Short: "Gets an API product from an organization", Long: "Gets an API product from an organization", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.Get(name) return }, }
GetCmd to get products
View Source
var ImpCmd = &cobra.Command{ Use: "import", Short: "Import a file containing API products", Long: "Import a file containing API products", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) error { return products.Import(conn, filePath) }, }
Cmd to import products
View Source
var ListAttrCmd = &cobra.Command{ Use: "list", Short: "List attributes of an API product", Long: "List attributes of an API product", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.ListAttributes(name) return }, }
ListAttrCmd to delete product attribute
View Source
var ListCmd = &cobra.Command{ Use: "list", Short: "Returns a list of API products", Long: "Returns a list of API products with a filter by attribute names and values if provided", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.List(count, expand) return }, }
Cmd to list products
View Source
var UpdAttrCmd = &cobra.Command{ Use: "update", Short: "Update an attribute of an API product", Long: "Update an attribute of an API product", Args: func(cmd *cobra.Command, args []string) (err error) { apiclient.SetApigeeOrg(org) return nil }, RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.UpdateAttribute(name, attrName, attrValue) return }, }
UpdAttrCmd to delete product attribute
View Source
var UpdateCmd = &cobra.Command{ Use: "update", Short: "Update an API product", Long: "Update an API product", RunE: func(cmd *cobra.Command, args []string) (err error) { _, err = products.Update(name, description, approval, displayName, quota, quotaInterval, quotaUnit, environments, proxies, scopes, attrs) return }, }
Cmd to update a product
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.