Skip to content

Commit

Permalink
rename mainflux_id to thing_id
Browse files Browse the repository at this point in the history
rename MFThing to ThingID
rename MFKey to ThingKey
rename mainflux_key to thing_key

Signed-off-by: SammyOina <[email protected]>
  • Loading branch information
SammyOina committed Jul 26, 2023
1 parent 847ddf7 commit 0e2de4c
Show file tree
Hide file tree
Showing 21 changed files with 217 additions and 217 deletions.
18 changes: 9 additions & 9 deletions api/openapi/bootstrap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ components:
Config:
type: object
properties:
mainflux_id:
thing_id:
type: string
format: uuid
description: Corresponding Mainflux Thing ID.
Expand Down Expand Up @@ -312,11 +312,11 @@ components:
BootstrapConfig:
type: object
properties:
mainflux_id:
thing_id:
type: string
format: uuid
description: Corresponding Mainflux Thing ID.
mainflux_key:
thing_key:
type: string
format: uuid
description: Corresponding Mainflux Thing key.
Expand All @@ -338,14 +338,14 @@ components:
type: string
description: Issuing CA certificate.
required:
- mainflux_id
- mainflux_key
- thing_id
- thing_key
- mainflux_channels
- content
ConfigUpdateCerts:
type: object
properties:
mainflux_id:
thing_id:
type: string
format: uuid
description: Corresponding Mainflux Thing ID.
Expand All @@ -359,8 +359,8 @@ components:
type: string
description: Issuing CA certificate.
required:
- mainflux_id
- mainflux_key
- thing_id
- thing_key
- mainflux_channels
- content

Expand Down Expand Up @@ -429,7 +429,7 @@ components:
external_key:
type: string
description: External key.
mainflux_id:
thing_id:
type: string
description: ID of the corresponding Mainflux Thing.
channels:
Expand Down
18 changes: 9 additions & 9 deletions bootstrap/api/endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ func addEndpoint(svc bootstrap.Service) endpoint.Endpoint {
}

config := bootstrap.Config{
MFThing: req.ThingID,
ThingID: req.ThingID,
ExternalID: req.ExternalID,
ExternalKey: req.ExternalKey,
MFChannels: channels,
Expand All @@ -40,7 +40,7 @@ func addEndpoint(svc bootstrap.Service) endpoint.Endpoint {
}

res := configRes{
id: saved.MFThing,
id: saved.ThingID,
created: true,
}

Expand All @@ -61,7 +61,7 @@ func updateCertEndpoint(svc bootstrap.Service) endpoint.Endpoint {
}

res := updateConfigRes{
MFThing: cfg.MFThing,
ThingID: cfg.ThingID,
ClientCert: cfg.ClientCert,
CACert: cfg.CACert,
ClientKey: cfg.ClientKey,
Expand Down Expand Up @@ -94,8 +94,8 @@ func viewEndpoint(svc bootstrap.Service) endpoint.Endpoint {
}

res := viewRes{
MFThing: config.MFThing,
MFKey: config.MFKey,
ThingID: config.ThingID,
ThingKey: config.ThingKey,
Channels: channels,
ExternalID: config.ExternalID,
ExternalKey: config.ExternalKey,
Expand All @@ -117,7 +117,7 @@ func updateEndpoint(svc bootstrap.Service) endpoint.Endpoint {
}

config := bootstrap.Config{
MFThing: req.id,
ThingID: req.id,
Name: req.Name,
Content: req.Content,
}
Expand All @@ -127,7 +127,7 @@ func updateEndpoint(svc bootstrap.Service) endpoint.Endpoint {
}

res := configRes{
id: config.MFThing,
id: config.ThingID,
created: false,
}

Expand Down Expand Up @@ -186,8 +186,8 @@ func listEndpoint(svc bootstrap.Service) endpoint.Endpoint {
}

view := viewRes{
MFThing: cfg.MFThing,
MFKey: cfg.MFKey,
ThingID: cfg.ThingID,
ThingKey: cfg.ThingKey,
Channels: channels,
ExternalID: cfg.ExternalID,
ExternalKey: cfg.ExternalKey,
Expand Down
Loading

0 comments on commit 0e2de4c

Please sign in to comment.