- Move Server/Domain/DNSRecord/Bucket/StorageInstance/CDNInstance/Order/Error structs to internal/model/ - Provider interfaces now reference model.* types - Rainyun provider implementations import model package for data types - CLI commands updated to use model.DNSRecord directly Separates pure data structures from service contract interfaces, following hexagonal architecture: models (entities) live independently from ports (provider interfaces) and adapters (rainyun/* implementations).
20 lines
528 B
Go
20 lines
528 B
Go
package model
|
|
|
|
import "time"
|
|
|
|
type Domain struct {
|
|
ID string `json:"id" table:"ID"`
|
|
Name string `json:"name" table:"DOMAIN"`
|
|
Status string `json:"status" table:"STATUS"`
|
|
ExpireAt time.Time `json:"expires" table:"EXPIRES"`
|
|
Raw any `json:"-"`
|
|
}
|
|
|
|
type DNSRecord struct {
|
|
ID string `json:"id" table:"ID"`
|
|
Type string `json:"type" table:"TYPE"`
|
|
Name string `json:"name" table:"NAME"`
|
|
Value string `json:"value" table:"VALUE"`
|
|
TTL int `json:"ttl" table:"TTL"`
|
|
}
|