opnet 1.2.1 → 1.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/browser/_version.d.ts +1 -1
  2. package/browser/abi/shared/interfaces/motoswap/IAdministeredOP20.d.ts +21 -0
  3. package/browser/abi/shared/interfaces/motoswap/IMotoChefContract.d.ts +121 -0
  4. package/browser/abi/shared/interfaces/motoswap/IOwnableContract.d.ts +12 -0
  5. package/browser/abi/shared/interfaces/motoswap/IOwnableReentrancyGuardContract.d.ts +13 -0
  6. package/browser/abi/shared/interfaces/motoswap/IReentrancyGuardContract.d.ts +7 -0
  7. package/browser/abi/shared/json/motoswap/ADMINISTERD_OP_20_ABI.d.ts +3 -0
  8. package/browser/abi/shared/json/motoswap/MOTOSWAP_MOTOCHEF_ABI.d.ts +4 -0
  9. package/browser/abi/shared/json/motoswap/OWNABLE_ABI.d.ts +3 -0
  10. package/browser/abi/shared/json/motoswap/REENTRANCY_GUARD_ABI.d.ts +2 -0
  11. package/browser/index.js +1 -1
  12. package/browser/opnet.d.ts +4 -0
  13. package/build/_version.d.ts +1 -1
  14. package/build/_version.js +1 -1
  15. package/build/abi/shared/interfaces/motoswap/IAdministeredOP20.d.ts +21 -0
  16. package/build/abi/shared/interfaces/motoswap/IAdministeredOP20.js +1 -0
  17. package/build/abi/shared/interfaces/motoswap/IMotoChefContract.d.ts +121 -0
  18. package/build/abi/shared/interfaces/motoswap/IMotoChefContract.js +1 -0
  19. package/build/abi/shared/interfaces/motoswap/IOwnableContract.d.ts +12 -0
  20. package/build/abi/shared/interfaces/motoswap/IOwnableContract.js +1 -0
  21. package/build/abi/shared/interfaces/motoswap/IOwnableReentrancyGuardContract.d.ts +13 -0
  22. package/build/abi/shared/interfaces/motoswap/IOwnableReentrancyGuardContract.js +1 -0
  23. package/build/abi/shared/interfaces/motoswap/IReentrancyGuardContract.d.ts +7 -0
  24. package/build/abi/shared/interfaces/motoswap/IReentrancyGuardContract.js +1 -0
  25. package/build/abi/shared/json/motoswap/ADMINISTERD_OP_20_ABI.d.ts +3 -0
  26. package/build/abi/shared/json/motoswap/ADMINISTERD_OP_20_ABI.js +81 -0
  27. package/build/abi/shared/json/motoswap/MOTOSWAP_MOTOCHEF_ABI.d.ts +4 -0
  28. package/build/abi/shared/json/motoswap/MOTOSWAP_MOTOCHEF_ABI.js +443 -0
  29. package/build/abi/shared/json/motoswap/OWNABLE_ABI.d.ts +3 -0
  30. package/build/abi/shared/json/motoswap/OWNABLE_ABI.js +35 -0
  31. package/build/abi/shared/json/motoswap/REENTRANCY_GUARD_ABI.d.ts +2 -0
  32. package/build/abi/shared/json/motoswap/REENTRANCY_GUARD_ABI.js +15 -0
  33. package/build/opnet.d.ts +4 -0
  34. package/build/opnet.js +4 -0
  35. package/package.json +2 -2
  36. package/src/_version.ts +1 -1
  37. package/src/abi/shared/interfaces/motoswap/IAdministeredOP20.ts +56 -0
  38. package/src/abi/shared/interfaces/motoswap/IMotoChefContract.ts +348 -0
  39. package/src/abi/shared/interfaces/motoswap/IOwnableContract.ts +32 -0
  40. package/src/abi/shared/interfaces/motoswap/IOwnableReentrancyGuardContract.ts +33 -0
  41. package/src/abi/shared/interfaces/motoswap/IReentrancyGuardContract.ts +18 -0
  42. package/src/abi/shared/json/motoswap/ADMINISTERD_OP_20_ABI.ts +85 -0
  43. package/src/abi/shared/json/motoswap/MOTOSWAP_MOTOCHEF_ABI.ts +455 -0
  44. package/src/abi/shared/json/motoswap/OWNABLE_ABI.ts +38 -0
  45. package/src/abi/shared/json/motoswap/REENTRANCY_GUARD_ABI.ts +20 -0
  46. package/src/opnet.ts +4 -0
@@ -1 +1 @@
1
- export declare const version = "1.2.1";
1
+ export declare const version = "1.2.2";
@@ -0,0 +1,21 @@
1
+ import { Address } from '@btc-vision/transaction';
2
+ import { IOP_20Contract } from '../opnet/IOP_20Contract';
3
+ import { CallResult } from '../../../../opnet';
4
+ export type Admin = CallResult<{
5
+ ADDRESS: Address;
6
+ }>;
7
+ export type ChangeAdmin = CallResult<{
8
+ success: boolean;
9
+ }>;
10
+ export type AdminMint = CallResult<{
11
+ success: boolean;
12
+ }>;
13
+ export type AdminBurn = CallResult<{
14
+ success: boolean;
15
+ }>;
16
+ export interface IAdministeredOP20Contract extends IOP_20Contract {
17
+ admin(): Promise<Admin>;
18
+ changeAdmin(newAdmin: Address): Promise<ChangeAdmin>;
19
+ adminMint(to: Address, amount: bigint): Promise<AdminMint>;
20
+ adminBurn(from: Address, amount: bigint): Promise<AdminBurn>;
21
+ }
@@ -0,0 +1,121 @@
1
+ import { Address } from '@btc-vision/transaction';
2
+ import { IOwnableReentrancyGuardContract } from './IOwnableReentrancyGuardContract';
3
+ import { CallResult } from '../../../../opnet';
4
+ export type PoolInfo = {
5
+ allocPoint: number;
6
+ lastRewardBlock: number;
7
+ accMotoPerShare: bigint;
8
+ };
9
+ export type UserInfo = {
10
+ amount: bigint;
11
+ rewardDebt: bigint;
12
+ };
13
+ export type Initialize = CallResult<{
14
+ success: boolean;
15
+ }>;
16
+ export type GetLpToken = CallResult<{
17
+ lpTokenAddress: Address;
18
+ }>;
19
+ export type GetRewarder = CallResult<{
20
+ rewarderAddress: Address;
21
+ }>;
22
+ export type GetPoolInfo = CallResult<PoolInfo>;
23
+ export type GetUserInfo = CallResult<UserInfo>;
24
+ export type Pools = CallResult<{
25
+ poolLength: number;
26
+ poolsData: Uint8Array;
27
+ }>;
28
+ export type TotalAllocPoint = CallResult<{
29
+ totalAllocPoint: bigint;
30
+ }>;
31
+ export type Devaddr = CallResult<{
32
+ devaddr: Address;
33
+ }>;
34
+ export type MotoPerBlock = CallResult<{
35
+ motoPerBlock: bigint;
36
+ }>;
37
+ export type BonusEndBlock = CallResult<{
38
+ bonusEndBlock: bigint;
39
+ }>;
40
+ export type BonusMultiplier = CallResult<{
41
+ bonusMultiplier: bigint;
42
+ }>;
43
+ export type Add = CallResult<{
44
+ success: boolean;
45
+ }>;
46
+ export type Set = CallResult<{
47
+ success: boolean;
48
+ }>;
49
+ export type SetMigrator = CallResult<{
50
+ success: boolean;
51
+ }>;
52
+ export type Migrate = CallResult<{
53
+ success: boolean;
54
+ }>;
55
+ export type GetMultiplier = CallResult<{
56
+ multiplier: bigint;
57
+ }>;
58
+ export type PendingMoto = CallResult<{
59
+ pendingMoto: number;
60
+ }>;
61
+ export type MassUpdatePools = CallResult<{
62
+ success: boolean;
63
+ }>;
64
+ export type UpdatePool = CallResult<PoolInfo>;
65
+ export type Deposit = CallResult<{
66
+ success: boolean;
67
+ }>;
68
+ export type Withdraw = CallResult<{
69
+ success: boolean;
70
+ }>;
71
+ export type Harvest = CallResult<{
72
+ success: boolean;
73
+ }>;
74
+ export type WithdrawAndHarvest = CallResult<{
75
+ success: boolean;
76
+ }>;
77
+ export type SetDev = CallResult<{
78
+ success: boolean;
79
+ }>;
80
+ export type SetMotoPerBlock = CallResult<{
81
+ success: boolean;
82
+ }>;
83
+ export type SetBonusEndBlock = CallResult<{
84
+ success: boolean;
85
+ }>;
86
+ export type SetBonusMultiplier = CallResult<{
87
+ success: boolean;
88
+ }>;
89
+ export type EmergencyWithdraw = CallResult<{
90
+ success: boolean;
91
+ }>;
92
+ export interface IMotoChefContract extends IOwnableReentrancyGuardContract {
93
+ initialize(MOTO: Address, premineAmount: bigint, devaddr: Address, motoPerBlock: bigint, bonusEndBlock: bigint, bonusMultiplier: bigint): Promise<Initialize>;
94
+ getLpToken(pid: number): Promise<GetLpToken>;
95
+ getRewarder(pid: number): Promise<GetRewarder>;
96
+ getPoolInfo(pid: number): Promise<GetPoolInfo>;
97
+ getUserInfo(pid: number, user: Address): Promise<GetUserInfo>;
98
+ pools(): Promise<Pools>;
99
+ totalAllocPoint(): Promise<TotalAllocPoint>;
100
+ devaddr(): Promise<Devaddr>;
101
+ getMotoPerBlock(): Promise<MotoPerBlock>;
102
+ getBonusEndBlock(): Promise<BonusEndBlock>;
103
+ getBonusMultiplier(): Promise<BonusMultiplier>;
104
+ setMotoPerBlock(motoPerBlock: bigint): Promise<SetMotoPerBlock>;
105
+ setBonusEndBlock(bonusEndBlock: bigint): Promise<SetBonusEndBlock>;
106
+ setBonusMultiplier(bonusMultiplier: bigint): Promise<SetBonusMultiplier>;
107
+ add(allocPoint: bigint, lpToken: Address, rewarder: Address): Promise<Add>;
108
+ set(pid: number, allocPoint: bigint, rewarder: Address, overwrite: boolean): Promise<Set>;
109
+ setMigrator(migrator: Address): Promise<SetMigrator>;
110
+ migrate(pid: number): Promise<Migrate>;
111
+ getMultiplier(from: bigint, to: bigint): Promise<GetMultiplier>;
112
+ pendingMoto(pid: number, user: Address): Promise<PendingMoto>;
113
+ massUpdatePools(length: number, pids: number[]): Promise<MassUpdatePools>;
114
+ updatePool(pid: number): Promise<UpdatePool>;
115
+ deposit(pid: number, amount: bigint, to: Address): Promise<Deposit>;
116
+ withdraw(pid: number, amount: bigint, to: Address): Promise<Withdraw>;
117
+ harvest(pid: number, to: Address): Promise<Harvest>;
118
+ withdrawAndHarvest(pid: number, amount: bigint, to: Address): Promise<WithdrawAndHarvest>;
119
+ emergencyWithdraw(pid: number, to: Address): Promise<EmergencyWithdraw>;
120
+ setDev(devaddr: Address): Promise<SetDev>;
121
+ }
@@ -0,0 +1,12 @@
1
+ import { Address } from '@btc-vision/transaction';
2
+ import { CallResult, IOP_NETContract } from '../../../../opnet';
3
+ export type Admin = CallResult<{
4
+ adminAddress: Address;
5
+ }>;
6
+ export type ChangeAdmin = CallResult<{
7
+ success: boolean;
8
+ }>;
9
+ export interface IOwnableContract extends IOP_NETContract {
10
+ admin(): Promise<Admin>;
11
+ changeAdmin(newAdmin: Address): Promise<ChangeAdmin>;
12
+ }
@@ -0,0 +1,13 @@
1
+ import { Address } from '@btc-vision/transaction';
2
+ import { CallResult } from '../../../../opnet';
3
+ import { IReentrancyGuard } from './IReentrancyGuardContract';
4
+ export type Admin = CallResult<{
5
+ adminAddress: Address;
6
+ }>;
7
+ export type ChangeAdmin = CallResult<{
8
+ success: boolean;
9
+ }>;
10
+ export interface IOwnableReentrancyGuardContract extends IReentrancyGuard {
11
+ admin(): Promise<Admin>;
12
+ changeAdmin(newAdmin: Address): Promise<ChangeAdmin>;
13
+ }
@@ -0,0 +1,7 @@
1
+ import { CallResult, IOP_NETContract } from '../../../../opnet';
2
+ export type Status = CallResult<{
3
+ status: bigint;
4
+ }>;
5
+ export interface IReentrancyGuard extends IOP_NETContract {
6
+ status(): Promise<Status>;
7
+ }
@@ -0,0 +1,3 @@
1
+ import { BitcoinInterfaceAbi } from '../../../interfaces/BitcoinInterfaceAbi';
2
+ declare const ADMINISTERED_OP_20_ABI: BitcoinInterfaceAbi;
3
+ export default ADMINISTERED_OP_20_ABI;
@@ -0,0 +1,4 @@
1
+ import { BitcoinInterfaceAbi } from '../../../interfaces/BitcoinInterfaceAbi';
2
+ export declare const MotoChefEvents: BitcoinInterfaceAbi;
3
+ declare const MOTOCHEF_ABI: BitcoinInterfaceAbi;
4
+ export default MOTOCHEF_ABI;
@@ -0,0 +1,3 @@
1
+ import { BitcoinInterfaceAbi } from '../../../interfaces/BitcoinInterfaceAbi';
2
+ declare const OWNABLE_ABI: BitcoinInterfaceAbi;
3
+ export default OWNABLE_ABI;
@@ -0,0 +1,2 @@
1
+ import { BitcoinInterfaceAbi } from '../../../interfaces/BitcoinInterfaceAbi';
2
+ export declare const REENTRANCY_GUARD_ABI: BitcoinInterfaceAbi;