test-kohin-sdk
Version:
The Kohin JS is a comprehensive developer toolkit designed to integrate Kohin's decentralized insurance system seamlessly into your applications. It enables efficient interaction with Kohin smart contracts and backend APIs, facilitating management and ana
648 lines (647 loc) • 15.9 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.comboPremiumCal = void 0;
exports.comboPremiumCal = [
{
inputs: [],
name: "InvalidInitialization",
type: "error",
},
{
inputs: [],
name: "NotInitializing",
type: "error",
},
{
inputs: [],
name: "OnlyPolicyManager",
type: "error",
},
{
inputs: [],
name: "ReentrancyGuardReentrantCall",
type: "error",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "newAccessControl",
type: "address",
},
],
name: "AccessControlUpdated",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint64",
name: "version",
type: "uint64",
},
],
name: "Initialized",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "enum IPolicyManager.BetType",
name: "betType",
type: "uint8",
},
{
indexed: false,
internalType: "uint256",
name: "minOdds",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "maxOdds",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "minAmount",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "maxAmount",
type: "uint256",
},
],
name: "LimitsUpdated",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "previousOwner",
type: "address",
},
{
indexed: true,
internalType: "address",
name: "newOwner",
type: "address",
},
],
name: "OwnershipTransferred",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "newPolicyManager",
type: "address",
},
],
name: "PolicyManagerUpdated",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint256",
name: "newOddsScoreWeight",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "newLegsScoreWeight",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "newNearMissScoreWeight",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "newBaseRate",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "newProfitMargin",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "newMaxPremiumCap",
type: "uint256",
},
{
indexed: false,
internalType: "uint256",
name: "newDefaultNearMiss",
type: "uint256",
},
{
indexed: false,
internalType: "uint8",
name: "newMaxSubBetLimit",
type: "uint8",
},
],
name: "PremiumCalculationConfigUpdated",
type: "event",
},
{
inputs: [],
name: "accessControl",
outputs: [
{
internalType: "contract IAccessControl",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "betLimits",
outputs: [
{
internalType: "uint256",
name: "minOdds",
type: "uint256",
},
{
internalType: "uint256",
name: "maxOdds",
type: "uint256",
},
{
internalType: "uint256",
name: "minAmount",
type: "uint256",
},
{
internalType: "uint256",
name: "maxAmount",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "odds",
type: "uint256",
},
{
internalType: "uint8",
name: "numLegs",
type: "uint8",
},
{
internalType: "uint256",
name: "stake",
type: "uint256",
},
],
name: "calculateInsurancePremium",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "account",
type: "address",
},
],
name: "checkOwner",
outputs: [],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "odds",
type: "uint256",
},
{
internalType: "uint8",
name: "numLegs",
type: "uint8",
},
{
internalType: "uint256",
name: "stake",
type: "uint256",
},
],
name: "getInsurancePremium",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "_accessControl",
type: "address",
},
],
name: "initialize",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint8",
name: "",
type: "uint8",
},
],
name: "legRiskScoreLookup",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "maxSubBetLimit",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint8",
name: "",
type: "uint8",
},
],
name: "nearMissLookup",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "owner",
outputs: [
{
internalType: "address",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint8",
name: "",
type: "uint8",
},
],
name: "participationFactorLookup",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "policyManager",
outputs: [
{
internalType: "address",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint8",
name: "",
type: "uint8",
},
],
name: "riskMultiplierLookup",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
name: "riskMultiplierThresholdKeys",
outputs: [
{
internalType: "uint8",
name: "",
type: "uint8",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint8",
name: "",
type: "uint8",
},
],
name: "riskMultiplierThresholds",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "newAccessControl",
type: "address",
},
],
name: "setAccessControl",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint8[]",
name: "keys",
type: "uint8[]",
},
{
internalType: "uint256[]",
name: "values",
type: "uint256[]",
},
],
name: "setLegRiskScoreLookup",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint8[]",
name: "keys",
type: "uint8[]",
},
{
internalType: "uint256[]",
name: "values",
type: "uint256[]",
},
],
name: "setNearMissLookup",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint8[]",
name: "keys",
type: "uint8[]",
},
{
internalType: "uint256[]",
name: "values",
type: "uint256[]",
},
],
name: "setParticipationFactorLookup",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "newPolicyManager",
type: "address",
},
],
name: "setPolicyManager",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint256[]",
name: "newThresholds",
type: "uint256[]",
},
{
internalType: "uint256[]",
name: "newMultipliers",
type: "uint256[]",
},
],
name: "setRiskMultiplierLookup",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "newOwner",
type: "address",
},
],
name: "transferOwnership",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
components: [
{
internalType: "uint256",
name: "minOdds",
type: "uint256",
},
{
internalType: "uint256",
name: "maxOdds",
type: "uint256",
},
{
internalType: "uint256",
name: "minAmount",
type: "uint256",
},
{
internalType: "uint256",
name: "maxAmount",
type: "uint256",
},
],
internalType: "struct IPremiumCalculator.BetLimits",
name: "betData",
type: "tuple",
},
],
name: "updateBetLimits",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "newOddsScoreWeight",
type: "uint256",
},
{
internalType: "uint256",
name: "newLegsScoreWeight",
type: "uint256",
},
{
internalType: "uint256",
name: "newNearMissScoreWeight",
type: "uint256",
},
{
internalType: "uint256",
name: "newBaseRate",
type: "uint256",
},
{
internalType: "uint256",
name: "newProfitMargin",
type: "uint256",
},
{
internalType: "uint256",
name: "newMaxPremiumCap",
type: "uint256",
},
{
internalType: "uint256",
name: "newDefaultNearMiss",
type: "uint256",
},
{
internalType: "uint8",
name: "newMaxSubBetLimit",
type: "uint8",
},
],
name: "updatePremiumCalculationConfig",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
];