You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
399 B
20 lines
399 B
package keybase |
|
|
|
func ExampleKeybase_AdvertiseCommand() { |
|
var k = NewKeybase() |
|
|
|
// Clear out any previously advertised commands |
|
k.ClearCommands() |
|
|
|
// Create BotAdvertisement |
|
c := BotAdvertisement{ |
|
Type: "public", |
|
BotCommands: []BotCommand{ |
|
NewBotCommand("help", "Get help using this bot"), |
|
NewBotCommand("hello", "Say hello"), |
|
}, |
|
} |
|
|
|
// Send advertisement |
|
k.AdvertiseCommand(c) |
|
}
|
|
|