2019-12-24 00:30:44 +08:00
|
|
|
// Copyright (c) Mainflux
|
|
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
|
|
|
package api
|
|
|
|
|
2022-01-28 00:03:57 +08:00
|
|
|
import "github.com/mainflux/mainflux/pkg/errors"
|
2019-12-24 00:30:44 +08:00
|
|
|
|
|
|
|
type browseReq struct {
|
|
|
|
ServerURI string
|
|
|
|
Namespace string
|
|
|
|
Identifier string
|
|
|
|
}
|
|
|
|
|
|
|
|
func (req *browseReq) validate() error {
|
2020-02-27 08:06:14 +08:00
|
|
|
if req.ServerURI == "" {
|
2022-01-28 00:03:57 +08:00
|
|
|
return errors.ErrMalformedEntity
|
2019-12-24 00:30:44 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
return nil
|
|
|
|
}
|