Initial commit
This commit is contained in:
14
models/hostname.go
Normal file
14
models/hostname.go
Normal file
@ -0,0 +1,14 @@
|
||||
package models
|
||||
|
||||
import "time"
|
||||
|
||||
// Hostname Model
|
||||
// @Description Model of the Hostname as it
|
||||
// @Description is represented in the database
|
||||
type Hostname struct {
|
||||
ID int `json:"id"` // Internal ID of the Hostname within the database
|
||||
Category string `json:"category"` // Category / Rule that was used when generating the hostname
|
||||
Hostname string `json:"hostname"` // Generated hostname
|
||||
Parameters map[string]interface{} `json:"parameters"` // Parameter object of rule specific attributes
|
||||
CreatedAt time.Time `json:"created_at"` // Creation Time of the entry
|
||||
}
|
9
models/login.go
Normal file
9
models/login.go
Normal file
@ -0,0 +1,9 @@
|
||||
package models
|
||||
|
||||
// User Credentials Model
|
||||
// @Description User account information used in the login process
|
||||
// @Description with Username and password
|
||||
type LoginCredentials struct {
|
||||
Username string `json:"username"`
|
||||
Password string `json:"password"`
|
||||
}
|
10
models/user.go
Normal file
10
models/user.go
Normal file
@ -0,0 +1,10 @@
|
||||
package models
|
||||
|
||||
// User Model
|
||||
// @Description User account information
|
||||
// @Description with user id and username
|
||||
type User struct {
|
||||
ID int // Database ID for the User
|
||||
Username string // Username
|
||||
Password string // hashed password
|
||||
}
|
Reference in New Issue
Block a user