(deps commandDeps)
| 887 | } |
| 888 | |
| 889 | func newTaskNotificationDeleteCommand(deps commandDeps) *cobra.Command { |
| 890 | return &cobra.Command{ |
| 891 | Use: "delete <task-id> <subscription-id>", |
| 892 | Short: "Delete one bridge terminal notification subscription", |
| 893 | Args: exactTwoNonBlankArgs(), |
| 894 | RunE: func(cmd *cobra.Command, args []string) error { |
| 895 | client, err := clientFromDeps(deps) |
| 896 | if err != nil { |
| 897 | return err |
| 898 | } |
| 899 | if err := client.DeleteTaskBridgeNotificationSubscription(cmd.Context(), args[0], args[1]); err != nil { |
| 900 | return err |
| 901 | } |
| 902 | return writeCommandOutput( |
| 903 | cmd, |
| 904 | taskBridgeNotificationSubscriptionDeleteBundle(args[0], args[1]), |
| 905 | ) |
| 906 | }, |
| 907 | } |
| 908 | } |
| 909 | |
| 910 | func buildTaskBridgeNotificationSubscriptionRequest( |
| 911 | input taskNotificationSubscribeInput, |
no test coverage detected