randomness-js
Version:
A library for consuming, verifying and using randomness from the dcipher network
139 lines (135 loc) • 2.89 kB
text/typescript
/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
import { Contract, Interface, type ContractRunner } from "ethers";
import type {
IRandomnessSender,
IRandomnessSenderInterface,
} from "../IRandomnessSender";
const _abi = [
{
type: "function",
name: "getAllRequests",
inputs: [],
outputs: [
{
name: "",
type: "tuple[]",
internalType: "struct TypesLib.RandomnessRequest[]",
components: [
{
name: "nonce",
type: "uint256",
internalType: "uint256",
},
{
name: "callback",
type: "address",
internalType: "address",
},
],
},
],
stateMutability: "view",
},
{
type: "function",
name: "getRequest",
inputs: [
{
name: "requestId",
type: "uint256",
internalType: "uint256",
},
],
outputs: [
{
name: "",
type: "tuple",
internalType: "struct TypesLib.RandomnessRequest",
components: [
{
name: "nonce",
type: "uint256",
internalType: "uint256",
},
{
name: "callback",
type: "address",
internalType: "address",
},
],
},
],
stateMutability: "view",
},
{
type: "function",
name: "messageFrom",
inputs: [
{
name: "r",
type: "tuple",
internalType: "struct TypesLib.RandomnessRequest",
components: [
{
name: "nonce",
type: "uint256",
internalType: "uint256",
},
{
name: "callback",
type: "address",
internalType: "address",
},
],
},
],
outputs: [
{
name: "",
type: "bytes",
internalType: "bytes",
},
],
stateMutability: "pure",
},
{
type: "function",
name: "requestRandomness",
inputs: [],
outputs: [
{
name: "requestID",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "nonpayable",
},
{
type: "function",
name: "setSignatureSender",
inputs: [
{
name: "newSignatureSender",
type: "address",
internalType: "address",
},
],
outputs: [],
stateMutability: "nonpayable",
},
] as const;
export class IRandomnessSender__factory {
static readonly abi = _abi;
static createInterface(): IRandomnessSenderInterface {
return new Interface(_abi) as IRandomnessSenderInterface;
}
static connect(
address: string,
runner?: ContractRunner | null
): IRandomnessSender {
return new Contract(address, _abi, runner) as unknown as IRandomnessSender;
}
}