package common

import (
	"time"

	"github.com/pingcap/test-infra/common/model"
)

type HistoryListOpts struct {
	FromTs, ToTs *time.Time
	Offset       uint
	Count        uint `default:"20"`
}

type HistoryGetOpts struct {
	Revision *model.ID

	// Get the most recently record which was created before the `Ts`.
	// Uncompcatable with `revision`.
	Ts *time.Time
}

type HistoryCreateOpts struct {
	// User that performed the action.
	User model.ID

	// Action that was performed.
	Action model.HistoryAction

	// Ts is the timestamp of the action.
	Ts *time.Time
}
