func DeclaredCaveat(key string, value string) Caveat {
	if strings.Contains(key, " ") || key == "" {
		return ErrorCaveatf("invalid caveat 'declared' key %q", key)
	}
	return firstParty(CondDeclared, key+" "+value)
}
DeclaredCaveat returns a "declared" caveat asserting that the given key is
set to the given value. If a macaroon has exactly one first party
caveat asserting the value of a particular key, then InferDeclared
will be able to infer the value, and then DeclaredChecker will allow
the declared value if it has the value specified here.

If the key is empty or contains a space, DeclaredCaveat
will return an error caveat.
package checkers
import (
	"strings"
	"golang.org/x/net/context"
	"gopkg.in/errgo.v1"
	"gopkg.in/macaroon.v2"
)
type macaroonsKey struct{}
type macaroonsValue struct {
	ns *Namespace
	ms macaroon.Slice
}
func ContextWithMacaroons(ctx context.Context, ns *Namespace, ms macaroon.Slice) context.Context {
	return context.WithValue(ctx, macaroonsKey{}, macaroonsValue{
		ns: ns,
		ms: ms,
	})
}
func MacaroonsFromContext(ctx context.Context) (*Namespace, macaroon.Slice) {
	v, _ := ctx.Value(macaroonsKey{}).(macaroonsValue)
	return v.ns, v.ms
}