syntax = "proto3";
package band.feeds.v1beta1;

option go_package = "github.com/bandprotocol/chain/v3/x/feeds/types";

import "gogoproto/gogo.proto";
import "cosmos_proto/cosmos.proto";

// Params is the data structure that keeps the parameters of the feeds module.
message Params {
  option (gogoproto.equal) = true; // Use gogoproto.equal for proto3 message equality checks

  // admin is the address of the admin that is allowed to update reference source config on modules.
  string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"];

  // allowable_block_time_discrepancy is the allowed discrepancy (in seconds) between validator price timestamp and
  // block_time.
  int64 allowable_block_time_discrepancy = 2;

  // grace_period is the time (in seconds) given for validators to adapt to changing in feed's interval.
  int64 grace_period = 3;

  // min_interval is the minimum limit of every feeds' interval (in seconds).
  // If the calculated interval is lower than this, it will be capped at this value.
  int64 min_interval = 4;

  // max_interval is the maximum limit of every feeds' interval (in seconds).
  // If the calculated interval of a feed is higher than this, it will not be capped at this value.
  int64 max_interval = 5;

  // power_step_threshold is the amount of minimum power required to put feed in the current feeds list.
  int64 power_step_threshold = 6;

  // max_current_feeds is the maximum number of feeds supported at a time.
  uint64 max_current_feeds = 7;

  // cooldown_time represents the duration (in seconds) during which validators are prohibited from sending new prices.
  int64 cooldown_time = 8;

  // min_deviation_basis_point is the minimum limit of every feeds' deviation (in basis point).
  int64 min_deviation_basis_point = 9;

  // max_deviation_basis_point is the maximum limit of every feeds' deviation (in basis point).
  int64 max_deviation_basis_point = 10;

  // current_feeds_update_interval is the number of blocks after which the current feeds will be re-calculated.
  int64 current_feeds_update_interval = 11;

  // price_quorum is the minimum percentage of power that needs to be reached for a price to be processed.
  string price_quorum = 12;

  // max_signal_ids_per_signing is the maximum number of signals allowed in a single tss signing request.
  uint64 max_signal_ids_per_signing = 13 [(gogoproto.customname) = "MaxSignalIDsPerSigning"];
}
