developers

package
v1.125.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 19, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AdjustCmd = &cobra.Command{
	Use:   "adjust",
	Short: "Adjust the prepaid balance for the developer",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	Long: "Adjust the prepaid balance for the developer",
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.Adjust(email, adjust)
		return
	},
}

AdjustCmd to list developer subscriptions

View Source
var Cmd = &cobra.Command{
	Use:     "developers",
	Aliases: []string{"devs"},
	Short:   "Manage Apigee App Developers",
	Long:    "Manage Apigee App Developers",
}

Cmd to manage developers

View Source
var CreateCmd = &cobra.Command{
	Use:   "create",
	Short: "Create a developer",
	Long:  "Create a developer",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.Create(email, firstName, lastName, userName, attrs)
		return
	},
}

CreateCmd to create developer

View Source
var CreateSubCmd = &cobra.Command{
	Use:   "create",
	Short: "Create a subcription for a developer",
	Long:  "Create a developer",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.CreateSubscription(email, name, apiproduct, startTime, endTime)
		return
	},
}

CreateSubCmd to create developer subscription

View Source
var CreditCmd = &cobra.Command{
	Use:   "credit",
	Short: "Credits the account balance for the developer",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	Long: "Credits the account balance for the developer",
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.Credit(email, credit)
		return
	},
}

CreditCmd to list developer subscriptions

View Source
var DelCmd = &cobra.Command{
	Use:   "delete",
	Short: "Deletes an App Developer from an organization",
	Long:  "Deletes an App Developer from an organization",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.Delete(email)
		return
	},
}

DelCmd to delete developer

View Source
var ExpCmd = &cobra.Command{
	Use:   "export",
	Short: "Export Developers to a file",
	Long:  "Export Developers to a file",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		const exportFileName = "developers.json"

		respBody, err := developers.Export()
		if err != nil {
			return err
		}

		return apiclient.WriteByteArrayToFile(exportFileName, false, respBody)
	},
}

ExpCmd to export developer

View Source
var ExpSubCmd = &cobra.Command{
	Use:   "expire",
	Short: "Expires a Developer subscription",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	Long: "Expires a Developer subscription",
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.ExpireSubscriptions(email, subscription)
		return
	},
}

ExpSubCmd to expire a developer subscription

View Source
var ExportSubCmd = &cobra.Command{
	Use:   "export",
	Short: "Export Developer subscriptions to a file",
	Long:  "Export Developer subscriptions to a file",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		exportFileName := "subscription_" + email + ".json"

		respBody, err := developers.ExportSubscriptions(email)
		if err != nil {
			return err
		}

		return apiclient.WriteByteArrayToFile(exportFileName, false, respBody)
	},
}

ExportSubCmd to export developer

View Source
var GetAppCmd = &cobra.Command{
	Use:   "getapps",
	Short: "Returns the apps owned by a developer by email address",
	Long:  "Returns the apps owned by a developer by email address",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.GetApps(name, expand)
		return
	},
}

GetAppCmd to get developer aps

View Source
var GetCmd = &cobra.Command{
	Use:   "get",
	Short: "Returns the profile for a developer by email address or ID",
	Long:  "Returns the profile for a developer by email address or ID",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.Get(email)
		return
	},
}

GetCmd to get developer

View Source
var GetSubCmd = &cobra.Command{
	Use:   "get",
	Short: "Returns a Developer subscription",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	Long: "Returns a Developer subscription",
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.GetSubscriptions(email, subscription)
		return
	},
}

GetSubCmd to list developer subscriptions

View Source
var ImpCmd = &cobra.Command{
	Use:   "import",
	Short: "Import a file containing App Developers",
	Long:  "Import a file containing App Developers",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) error {
		return developers.Import(conn, filePath)
	},
}

ImpCmd to import developer

View Source
var ListCmd = &cobra.Command{
	Use:   "list",
	Short: "Returns a list of App Developers",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	Long: "Lists all developers in an organization by email address",
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.List(count, expand, ids)
		return
	},
}

ListCmd to list developer

View Source
var ListSubCmd = &cobra.Command{
	Use:   "list",
	Short: "Returns a list of Developer subscriptions",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	Long: "Returns a list of Developer subscriptions",
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.ListSubscriptions(email)
		return
	},
}

ListSubCmd to list developer subscriptions

View Source
var SubCmd = &cobra.Command{
	Use:   "subscriptions",
	Short: "Manage subscriptions for a Developer",
	Long:  "Manage subscriptions for a Developer",
}

SubCmd to manage subscriptions of developers

View Source
var UpdateCmd = &cobra.Command{
	Use:   "update",
	Short: "Update an Apigee developer configuration",
	Long:  "Update an Apigee developer configuration",
	Args: func(cmd *cobra.Command, args []string) (err error) {
		return apiclient.SetApigeeOrg(org)
	},
	RunE: func(cmd *cobra.Command, args []string) (err error) {
		_, err = developers.Update(email, firstName, lastName, userName, cmd.Flag("status").Value.String(), attrs)
		return
	},
}

UpdateCmd to update developer

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL