// Generated by eosio-abi2ts 1.2.2 - eosio::abi/1.2

export type IName = string
export type IChecksum256 = string
export type IPublicKey = string
export type ISignature = string
export type ITimePointSec = string
export type IUint64 = number | string

export interface IAuthmeet {
  coopname: IName
  hash: IChecksum256
  authorization: IDocument
}

export interface IClosemeet {
  coopname: IName
  hash: IChecksum256
  meet_decision: IDocument
}

export interface ICreatemeet {
  coopname: IName
  hash: IChecksum256
  initiator: IName
  presider: IName
  secretary: IName
  agenda: IMeetPoint[]
  statement: IDocument
  open_at: ITimePointSec
  close_at: ITimePointSec
}

export interface IDeclmeet {
  coopname: IName
  hash: IChecksum256
  reason: string
}

export interface IDocument {
  hash: IChecksum256
  public_key: IPublicKey
  signature: ISignature
  meta: string
}

export interface IMeet {
  id: IUint64
  hash: IChecksum256
  coopname: IName
  type: IName
  initiator: IName
  presider: IName
  secretary: IName
  status: IName
  created_at: ITimePointSec
  open_at: ITimePointSec
  close_at: ITimePointSec
  quorum_percent: IUint64
  signed_ballots: IUint64
  current_quorum_percent: IUint64
  cycle: IUint64
  quorum_passed: boolean
  proposal: IDocument
  authorization: IDocument
}

export interface IMeetPoint {
  context: string
  title: string
  decision: string
}

export interface INewgdecision {
  coopname: IName
  hash: IChecksum256
  results: IQuestionResult[]
  signed_ballots: IUint64
  quorum_percent: IUint64
  quorum_passed: boolean
}

export interface IQuestion {
  id: IUint64
  number: IUint64
  coopname: IName
  meet_id: IUint64
  title: string
  context: string
  decision: string
  counter_votes_for: IUint64
  counter_votes_against: IUint64
  counter_votes_abstained: IUint64
  voters_for: IName[]
  voters_against: IName[]
  voters_abstained: IName[]
}

export interface IQuestionResult {
  question_id: IUint64
  title: string
  decision: string
  context: string
  votes_for: IUint64
  votes_against: IUint64
  votes_abstained: IUint64
  accepted: boolean
}

export interface IRestartmeet {
  coopname: IName
  hash: IChecksum256
  newproposal: IDocument
  new_open_at: ITimePointSec
  new_close_at: ITimePointSec
}

export interface IVote {
  coopname: IName
  hash: IChecksum256
  member: IName
  ballot: IVotePoint[]
}

export interface IVotePoint {
  question_id: IUint64
  vote: IName
}
