easybridge/mxlib/registration.go

27 lines
798 B
Go
Raw Normal View History

2020-02-16 18:30:49 +00:00
package mxlib
import (
_ "gopkg.in/yaml.v2"
)
type Registration struct {
2020-02-17 18:02:26 +00:00
Id string `yaml:"id"`
Url string `yaml:"url"`
AsToken string `yaml:"as_token"`
HsToken string `yaml:"hs_token"`
SenderLocalpart string `yaml:"sender_localpart"`
2020-02-23 19:24:50 +00:00
RateLimited bool `yaml:"rate_limited"`
2020-02-17 18:02:26 +00:00
Namespaces RegistrationNamespaceSet `yaml:"namespaces"`
2020-02-16 18:30:49 +00:00
}
type RegistrationNamespaceSet struct {
2020-02-17 18:02:26 +00:00
Users []RegistrationNamespace `yaml:"users"`
2020-02-16 18:30:49 +00:00
Aliases []RegistrationNamespace `yaml:"aliases"`
2020-02-17 18:02:26 +00:00
Rooms []RegistrationNamespace `yaml:"rooms"`
2020-02-16 18:30:49 +00:00
}
type RegistrationNamespace struct {
2020-02-17 18:02:26 +00:00
Exclusive bool `yaml:"exclusive"`
Regex string `yaml:"regex"`
2020-02-16 18:30:49 +00:00
}