code: func (cfg *Config) Validate(c *validation.Context) {
  	c.Enter("amount")
  	cfg.GetAmount().Validate(c)
  	c.Exit()
  	c.Enter("attributes")
  	cfg.GetAttributes().Validate(c)
  	c.Exit()
  	c.Enter("lifetime")
  	cfg.GetLifetime().Validate(c)
  	switch n, err := cfg.Lifetime.ToSeconds(); {
  	case err != nil:
  		c.Errorf("%s", err)
  	case n == 0:
  		c.Errorf("duration or seconds is required")
  	}
  	c.Exit()
  	if cfg.GetPrefix() == "" {
  		c.Errorf("prefix is required")
  	}
  	if cfg.GetRevision() != "" {
  		c.Errorf("revision must not be specified")
  	}
  	c.Enter("timeout")
  	cfg.GetTimeout().Validate(c)
  	c.Exit()
  }
docs: // Validate validates this config. Kind must already be applied.