feat: add basic workings

This commit is contained in:
2026-04-29 23:38:43 +02:00
parent da3dee9ae7
commit 76c893ae7e
14 changed files with 167 additions and 112 deletions
+11 -11
View File
@@ -12,7 +12,7 @@ const (
CreationMes string = "Object successfully created"
DeletionMes string = "Object successfully deleted"
NotFoundMes string = "Requested object not found"
BadRequestMes string = "Request did not satisfy requirements"
BadRequestMes string = "Request did not satisfy requirements (bad request)"
ConflictMes string = "Duplicate object"
IntErrMes string = "An internal error occured, contact your administrator"
)
@@ -24,20 +24,20 @@ type ResponseObject struct {
// we swap out the hash for the keycontent
type KeyResponse struct {
ID int `json:"id"`
MetaName string `json:"metaName"`
KeyName string `json:"keyName"`
KeyContent string `json:"keyContent"`
Revoked bool `json:"revoked"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`
ExpiresAt time.Time `json:"expiresAt"`
ID int `json:"ID"`
MetaName string `json:"metaName"`
KeyID string `json:"keyID"`
KeySecret string `json:"keySecret"`
Revoked bool `json:"revoked"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`
ExpiresAt time.Time `json:"expiresAt"`
}
type FileResponse struct {
ID int `json:"id"`
ID int `json:"ID"`
MetaName string `json:"metaName"`
FileName string `json:"fileName"`
FileID string `json:"fileID"`
FilePath string `json:"filePath"`
Checksum string `json:"checksum"`
MediaType string `json:"mediaType"`