2025-05-08 14:02:58 +02:00

37 lines
701 B
Go

package main
type User struct {
ID int `json:"id"`
Name string `json:"name"`
}
type Allowance struct {
Allowance int `json:"allowance"`
Goals []Goal `json:"goals"`
}
type Schema struct {
Id int `json:"id"`
Name string `json:"name"`
Reward int `json:"reward"`
Assigned *int `json:"assigned"`
}
type Goal struct {
ID int `json:"id"`
Name string `json:"name"`
Target int `json:"target"`
Progress int `json:"progress"`
Weight int `json:"weight"`
}
type CreateGoalRequest struct {
Name string `json:"name"`
Target int `json:"target"`
Weight int `json:"weight"`
}
type CreateGoalResponse struct {
ID int `json:"id"`
}