nip11: add "supported_grasps" special field.
This commit is contained in:
@@ -51,6 +51,9 @@ func New(rl *khatru.Relay, repositoryDir string) *GraspServer {
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
rl.Info.AddSupportedNIP(34)
|
||||||
|
rl.Info.SupportedGrasps = append(rl.Info.SupportedGrasps, "GRASP-01")
|
||||||
|
|
||||||
base := rl.Router()
|
base := rl.Router()
|
||||||
mux := http.NewServeMux()
|
mux := http.NewServeMux()
|
||||||
|
|
||||||
|
|||||||
@@ -28,6 +28,9 @@ type RelayInformationDocument struct {
|
|||||||
Retention []*RelayRetentionDocument `json:"retention,omitempty"`
|
Retention []*RelayRetentionDocument `json:"retention,omitempty"`
|
||||||
Icon string `json:"icon,omitempty"`
|
Icon string `json:"icon,omitempty"`
|
||||||
Banner string `json:"banner,omitempty"`
|
Banner string `json:"banner,omitempty"`
|
||||||
|
|
||||||
|
// nip-34 grasp stuff
|
||||||
|
SupportedGrasps []string `json:"supported_grasps,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (info *RelayInformationDocument) AddSupportedNIP(number int) {
|
func (info *RelayInformationDocument) AddSupportedNIP(number int) {
|
||||||
|
|||||||
Reference in New Issue
Block a user